I mounted the hard drive by using the GUI in Mac.
However, I want to mount the hard drive by using the terminal commands.
How can I execute a terminal command mount_smbfs
from my Objective-C Cocoa application?
NSTask* task = [[NSTask alloc] init];
[task setLaunchPath:@"/sbin/mount_smbfs"];
[task setArguments:[NSArray arrayWithObjects:@"//user:50000@smb://192.168.2.1/Share",@"Volumes/C$/upload", nil]];
[task launch];
Here is my edited with my code Could you please help me?