fileexists() command?

Got an idea for enhancing PureBasic? New command(s) you'd like to see?
Dreglor
Enthusiast
Enthusiast
Posts: 759
Joined: Sat Aug 02, 2003 11:22 pm
Location: OR, USA

fileexists() command?

Post by Dreglor »

fileexists() command would be great it would also be quite useful
i pretty sure it not in there (yet)
~Dreglor
Berikco
Administrator
Administrator
Posts: 1326
Joined: Wed Apr 23, 2003 7:57 pm
Location: Belgium
Contact:

Post by Berikco »

This is probably an april 1 joke? :D

Code: Select all

If FileSize(Filename$) = -1
  Debug "File not found"
EndIf
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6166
Joined: Sat May 17, 2003 11:31 am
Contact:

Post by blueznl »

it's not a april 1 joke, it's just not very common to check for a file size if you want to know a file exist, most variations of basic have a command for that

yeah, it's in the faq, yeah, i was stupid enough to ask about it as well... :-)
( PB6.00 LTS Win11 x64 Asrock AB350 Pro4 Ryzen 5 3600 32GB GTX1060 6GB)
( The path to enlightenment and the PureBasic Survival Guide right here... )
Dreglor
Enthusiast
Enthusiast
Posts: 759
Joined: Sat Aug 02, 2003 11:22 pm
Location: OR, USA

Post by Dreglor »

sorry, thanks :)
~Dreglor
Post Reply