Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / [DBPro] Make File-open to write issues

Author
Message
Gamer Dude
14
Years of Service
User Offline
Joined: 25th Nov 2011
Location: DBPro
Posted: 26th Nov 2011 00:47
Okay, if i create a file using the Make File command, then use the Open To Write command, it doesn't open the file correctly.

I have coded in some error catching and the file is created, but not opened to write.

Code:


Any help would be much appreciated
IanM
Retired Moderator
23
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 26th Nov 2011 01:02
Don't use the MAKE FILE command. It has pretty much no use.

The OPEN TO WRITE command will silently fail if the file already exists - if you want to overwrite an existing file, use something like the following:


Gamer Dude
14
Years of Service
User Offline
Joined: 25th Nov 2011
Location: DBPro
Posted: 26th Nov 2011 01:36
Ok thanks, it works now

Login to post a reply

Server time is: 2026-07-10 07:37:56
Your offset time is: 2026-07-10 07:37:56