Just starting out? Need help? Post your questions and find answers here.
-
falsam
- Posts: 286
- Joined: Mon May 05, 2014 9:49 pm
- Location: France
-
Contact:
Post
by falsam »
Code: Select all
If CreateFile(0, "Text.txt")
CloseFile(0)
EndIf
the third parameter is not optional. It does not matter. Simply put ^^
Last edited by
falsam on Wed Jun 15, 2016 9:05 pm, edited 1 time in total.
➽ Windows 11 - jdk-11.0.2 - SB 3.00 - Android 15
➽ https://falsam.com
Sorry for my poor english
-
Peter
- Posts: 1197
- Joined: Mon Feb 24, 2014 10:17 pm
- Location: 127.0.0.1:9080
-
Contact:
Post
by Peter »
There are
four parameters. Only the fourth one is optional. The Online-Help is wrong.
But it seems, that the callback doesn't work:
Code: Select all
Procedure CreateFileCallback()
Debug "CreateFileCallback()"
CloseFile(0)
EndProcedure
CreateFile(0, "Text.txt", @CreateFileCallback())
Greetings ... Peter
-
falsam
- Posts: 286
- Joined: Mon May 05, 2014 9:49 pm
- Location: France
-
Contact:
Post
by falsam »
Hello Peter.
Oops I forgot to take a look at the bottom of the screen !!

➽ Windows 11 - jdk-11.0.2 - SB 3.00 - Android 15
➽ https://falsam.com
Sorry for my poor english
-
Fred
- Site Admin
- Posts: 1821
- Joined: Mon Feb 24, 2014 10:51 am
Post
by Fred »
The callback is only reported read/write operations, not creation
-
Peter
- Posts: 1197
- Joined: Mon Feb 24, 2014 10:17 pm
- Location: 127.0.0.1:9080
-
Contact:
Post
by Peter »
Fred wrote:The callback is only reported read/write operations, not creation
this one does not work either (?)
Code: Select all
Procedure myCallback()
Debug "myCallback()"
EndProcedure
If CreateFile(0, "Text.txt", @myCallback())
Debug "CreateFile()"
WriteStringN(0, "This")
WriteStringN(0, "is")
WriteStringN(0, "a")
WriteStringN(0, "test")
CloseFile(0)
Else
Debug "!CreateFile()"
EndIf
Greetings ... Peter