I have a PowerPoint 2003 Presentation that runs a VB 6 program. The
link was set up by using the Slide Show/Action Settings/Run Program
insert. With the Browse button, I can locate the desired program,
which runs great when viewing the slide show.
But there is a problem. If I shut down PowerPoint and start again some
time later, the next time I try to run the slide show, the link comes
up with file not found. This occurs even though the link label still
points to the correct program file name.
I can repeat the Slide Show/Action Settings/Run Program insert and get
it work again, but then it fails after shutting down and restarting
later.
Anybody got a solution here? All I'm trying to do is run a VB program
from a PowerPoint presentation.
How about embedded spaces in the path? Maybe some quotation marks
around the executable filename, as they would appear in a "shortcut"?
-- mathtalk-ga
Is the pathname to the executable fully qualified? It sounds like an
issue with "where's the current directory" and relative pathnames.
Just a thought...
-- mathtalk-ga
Hi again Skippy!
Do almost the same as with your word question.
Add a microsoft powerpoint (version) object reference and let your code
be something like:
Dim appPP As PowerPoint.Application
Dim PPDoc As PowerPoint.Presentation
Dim strFileName As String
strFileName = "c:test.ppt"
appPP = New PowerPoint.Application
appPP.Activate()
PPDoc = appPP.Presentations.Open(strFileName)
PPDoc.SlideShowSettings.Run() ' If you want the slide show to start
Hope this helps you.
-Trym
mathtalk,
I trield quotation marks, but it did not work.
I did find out something new, however. The program I am calling has to
load two other files that are in the same directory.
Because of the above, I wrote a simple "Hello World" program with no
called files. This clears the problem. Apparently, it is the files
being called that cannot be found.
Since the files being called are in the same directory as the program,
it seems strange that PowerPoint cannot locate the called-for files.
Skip DCC Wiring NMRA:: File Format: PDF/Adobe Acrobat - View as HTMLThis presentation limits it’s discussion to the most popular North .. The term “Gap” comes from the visual description of what happens at the rail joint. . There are two basic forms of wiring up a layout:. • Daisy Chain Rail is followed and fed by a single BIG wire running around the layout. http://www.siliconvalleylines.org/dcc/2006/Wiring.pdfHOME |
Yes, when you use the browse button to locate the program, it does
produce a complete path name starting with
c:directory1directory2directorty3filename.
Nice try, but the problem lies elsewhere. The strange thing is that a
label does appear on later tries that shows the complete path name,
and yet PP pops up a cannot find error. Totally illogical.
The problem you are experiencing is that the default path when
PowerPoint is started up is the PowerPoint path - not your VB
application's location path. I was able to reproduce your error by
trying to load files from with VB.
What you need to do is one of these two options:
1) Recompile the VB app to point to the full path to the extra files
reference - like 'c:myvbappcontrolfilesfile.txt' rather than just
'file.txt'.
or, if you can't change the VB app:
2) Create a new shortcut to PowerPoint. Right-click on the shortcut
and choose properties. In the line called 'Start in:' - put in the
path of your VB application. Press Apply. This will fix your problem
as long as all files referenced in the VB app are in the same
directory.
I tested both and that fixed your problem.
Hope that helps!
Haha skippy, I think I read this one too fast.
I'll see if I can find a solution, if you haven't already
Harr harr.
Im tired. Going to bed. Disregard everything I wrote.
;)
-Trym
Challenging Books For A 14 Year Old?
First guitar : acoustic or electric?
|