On Aug 3, 2005, at 11:43 PM, Schollnick, Benjamin wrote: >> Anyone have any idea on how to get the Machine Name from the Sharing >> Preference pane? >> The only real solution that I have thought up is to find the plist >> and >> read it from there.... >> > > <http://developer.apple.com/qa/qa2001/qa1078.html> > > The major problem with this is that I'm trying for a python > based solution.... > > So I guess I could use PyObj to bridge to Objective C... But > I've never touched that... (Sorry Bob! >grin<) > > Any ideas on a Python based solution?
Unless you're using ctypes or PyObjC to FFI those functions, there is no Python based solution that I'm aware of. Alternatively, you could of course write an extension in C or Pyrex. In general, if it wasn't part of MacOS 9 or isn't standard POSIX, you're not going to find it in the stdlib... except for a few CoreFoundation functions, which you shouldn't use anyway because some of them are/were broken. -bob _______________________________________________ Pythonmac-SIG maillist - Pythonmac-SIG@python.org http://mail.python.org/mailman/listinfo/pythonmac-sig