Hi
I am using the function FSMakeFSSpec() to get a valid FSSpec but still file is not created. I have made this program in QT Programming for Mac(C++ GUI programming kit by trolltech.org). I am trying to make a text file using programming.
I have used the following code:-
OSErr err;
FSSpec spec;
err=FSMakeFSSpec(0,0,"/unique/hello.txt",&spec);
if(err == fnfErr)
QMessageBox::information(0, "message","hiiiiiiiiii");
FSpCreate(&spec, 'CWIE', 'TEXT', smSystemScript);
I have included the following Libs in my application:-
LIBS+=/System/Library/Frameworks/Carbon.framework/Carbon
LIBS+=/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation
I have included the "Files.h" in my project settings:-
/System/Library/Frameworks/CoreServices.framework/CarbonCore.framework/Versions/A/Headers/Files.h
Plz help me where i am wrong??
Thanks and Regards
I am using the function FSMakeFSSpec() to get a valid FSSpec but still file is not created. I have made this program in QT Programming for Mac(C++ GUI programming kit by trolltech.org). I am trying to make a text file using programming.
I have used the following code:-
OSErr err;
FSSpec spec;
err=FSMakeFSSpec(0,0,"/unique/hello.txt",&spec);
if(err == fnfErr)
QMessageBox::information(0, "message","hiiiiiiiiii");
FSpCreate(&spec, 'CWIE', 'TEXT', smSystemScript);
I have included the following Libs in my application:-
LIBS+=/System/Library/Frameworks/Carbon.framework/Carbon
LIBS+=/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation
I have included the "Files.h" in my project settings:-
/System/Library/Frameworks/CoreServices.framework/CarbonCore.framework/Versions/A/Headers/Files.h
Plz help me where i am wrong??
Thanks and Regards