Open an external application

G

Guest

Within our company we use WRQ Reflections, as part of my job i programme vba
in both excel and Reflections.

I have managed to get Refections to open office applications when run, but i
can figure out the code to open a Reflections session from within Excel.

The extention for the sessions are .r1w

if anyone knows of any code i would be grateful.

Many thanks
 
G

Guest

Hi Gary,

thanks for the quick responce, all this is doing is opening the MS-DoS
window launching the cmd.exe file within the System32 folder?

Am i missing something?
 
G

Guest

You will need to replace
C:\Userguide.r1w
with your path and file name

This should work if the file associations are correct; that is, if you can
manually open the .r1w file by double-clikcing its icon.
 
G

Guest

I have it working without sub directories ie\ C:\Userguide.r1w but as soon as
i attempt to add folders it wont open ie\ C:\Folder1\Folder2\Userguide.r1w

Can you help
 
G

Guest

Hi Gary,

I've been testing and the code works as long as there are no breaks in the
folder name. Is there any fix to this.
 
G

Guest

Look at:

Sub Macro1()
ChDir ("c:\Documents and Settings\littlegary\Desktop")
x = Shell("cmd.exe /c Hello"" ""there.doc", 1)
End Sub

First, the blanks can be embedded in ChDir
Second, notice the quad-quoting for the file name in the Shell statement
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top