Need to use the file access commands for a add in I have been making, but i know I am doing something very stupid, but for the past 3 hours have come up short on what that is.
The most basic segmant of code to show this would be the following:
Code:
For some reason the handle always ends up being some random number not always negative or positive. No matter if the file tester.py exists or not.
I have no idea what I am doing wrong.
The most basic segmant of code to show this would be the following:
Code:
unsigned short name[30]={'\\','\\','f','l','s','0','\\','t','e','s','t','e','r','.','p','y',0};
handle=Bfile_OpenFile_OS(name,READ,0);
if (1){
void *vars[1]={&handle};
basic_printer8(NULL,"handle %i",vars,2,0,50,0,65535,NULL);
}
GetKey(&key);
For some reason the handle always ends up being some random number not always negative or positive. No matter if the file tester.py exists or not.
I have no idea what I am doing wrong.