PDA

View Full Version : Adding Header Files - i think its me but it might not be...




kristiaand
Dec 10, 2007, 01:20 PM
Hi All,
got a bit of a wierd problem, not sure if its me or Xcode BUT here goes.

i am looking to write a simple Cocoa App in objective C that allows a user to connect a network drive. (you click a button on the program and it automatically does the work for you)

so i went off to ADC and found a reference to NSfilemanager which seemed todo what i wanted (not sure if that was correct or not yet).

noticed it was in a file called.

NSFileManager.h

so i entered this into my header file in my program, i thought i was all done and dusted until i try to use code completion. i get no code insight for the new header file, is this correct?

also am i barking up the wrong tree using

createSymbolicLinkAtPath:pathContent:

when trying to establish a network connection????

can any of you fine, gifted people give me some insight into this problem...

thanks
kris



robbieduncan
Dec 10, 2007, 01:33 PM
You cannot add the header on it's own: it's part of a Framework. You should simply use the Cocoa header. And you are barking up the wrong tree completely with that method: it creates a symbolic link to a file/folder. It will not connect a network drive.

kristiaand
Dec 10, 2007, 03:56 PM
You cannot add the header on it's own: it's part of a Framework. You should simply use the Cocoa header. And you are barking up the wrong tree completely with that method: it creates a symbolic link to a file/folder. It will not connect a network drive.

Hi Robbie thanks for the reply, i already have the cocoa.h file included but when i read the info on ADC i assumed i needed to add this file, now i know i don't.

as for barking up the wrong tree i had a feeling i was do you or anyone else have a starting point i can work from regarding this?

robbieduncan
Dec 11, 2007, 04:18 AM
There is no simple API for what you want to do. You are going to have to call out to the various low level tools (smbclient etc).