FROM : ?????? ??????
DATE : Mon Mar 03 09:02:43 2008
Hello gurus,
You're my last hope :) Few days I'm trying to resolve a problem of finding servers on the local network (or domain). The task sounds simple: to make the app find all hosts around. Just like Finder does in Network section. I can find Macs (afp) and Windows (smb?), right?
I'm not sure, but something suggests me that the most suitable mean for this purpose is NSNetServiceBrowser class. I used searchForServicesOfType:inDomain: and actually succeded. I managed to find all AFP servers on the network. It did it with [browser searchForServicesOfType:"_afpovertcp._tcp" inDomain:@""]. But it failed to find Windows servers. Okay, I must admit that I know little about how network environment works on a Mac (and Win), but I tried to act the same way. I tried "_smb._tcp" or "_cifs._tcp" as type, but to no avail. Hovewer, it did it if I turned on SMB file sharing on a Mac. But no luck with Windows. It never found me any Windows server.
So I'm stuck. I thought it would be great if someone suggested a way to go.
I think that if Finder does it, it must be possible.
Thanks.
Victor.
DATE : Mon Mar 03 09:02:43 2008
Hello gurus,
You're my last hope :) Few days I'm trying to resolve a problem of finding servers on the local network (or domain). The task sounds simple: to make the app find all hosts around. Just like Finder does in Network section. I can find Macs (afp) and Windows (smb?), right?
I'm not sure, but something suggests me that the most suitable mean for this purpose is NSNetServiceBrowser class. I used searchForServicesOfType:inDomain: and actually succeded. I managed to find all AFP servers on the network. It did it with [browser searchForServicesOfType:"_afpovertcp._tcp" inDomain:@""]. But it failed to find Windows servers. Okay, I must admit that I know little about how network environment works on a Mac (and Win), but I tried to act the same way. I tried "_smb._tcp" or "_cifs._tcp" as type, but to no avail. Hovewer, it did it if I turned on SMB file sharing on a Mac. But no luck with Windows. It never found me any Windows server.
So I'm stuck. I thought it would be great if someone suggested a way to go.
I think that if Finder does it, it must be possible.
Thanks.
Victor.
| Related mails | Author | Date |
|---|---|---|
| No related mails found. | ||






Cocoa mail archive

