[Tutor] Query

Kent Johnson kent37 at tds.net
Mon Mar 6 19:38:48 CET 2006


Rob Lane wrote:
> Hey,
> 
> I am currently working on a final year project in college building a 3-D 
> virtual model of a building in a python based program called Vizard. I 
> have prepared a set of tutorials on powerpoint which i would like to 
> access by clicking on various objects in the building. e.g. Click on a 
> Window/Air Duct and then open a powerpoint presentation on the topic.
> 
> I was wondering if there is python code which will let me launch my 
> powerpoint presentations from with my virtual world.

os.system() will let you execute a command line, for example

os.system(r'"C:\Program Files\Microsoft Office\Office\POWERPNT.EXE" 
F:\Personal\TEACHI~1\TDDINT~1.PPT')

Note the use of a raw string to allow \ path separators and the 
double-quotes around the path to the exe because it has spaces in it.

Kent



More information about the Tutor mailing list