Well, we can mark this one as solved.

Simple enough, actually -- thanks to Chris and Demian for leading me to water.

The following code works on both Linux and Windows 7:

def OnDocs(self, event):
        """Opens the User's Guide in the default web browser"""
        fullpath = os.path.abspath('documentation/HTMLDocs/index.html')
        url_link = "file:///" + fullpath
        webbrowser.open(url_link)

This allows both platforms to have their own idiosyncratic path structures 
without having to create separate code for each.  It even chooses the correct 
browser!

I learned some more about Python today, too. I'd never explored the 'os.' 
library before, and now I see things a little more clearly.

Thanks again, guys!
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to