Sign in to follow this  
Followers 0
DaLiMan

@sw_hide

4 posts in this topic

When I run my app, I want it to be hidden.

It runs alright, but it won't hide, minimize etc....

RunWait( @Comspec & " /c start C:\progra~1\VCG\Files\Templates\VCG.csv", "", @SW_HIDE)

Share this post


Link to post
Share on other sites



That's because you're indirectally running your application. It's actually hiding the Command window from you, but that hidden command window opens up the file you pass it.

If you want your program to open in a hidden window, you're going to need to find out which application opens the csv file you referance, and directally run that. I'm not familiar with csv files, so I don't know what app you need to use to open it. However, as an example, I'm going to assume you have a program called CSVapp.exe in the Program Files folder. You could do this:

RunWait('C:\Program Files\CSVapp\CSVapp.exe C:\progra~1\VCG\Files\Templates\VCG.csv', "", @SW_HIDE)

Now you are directally running the application that handles the file, and that will be hidden.


[font="Optima"]"Standing in the rain, twisted and insane, we are holding onto nothing.Feeling every breath, holding no regrets, we're still looking out for something."[/font]Note: my projects are off-line until I can spend more time to make them compatable with syntax changes.

Share this post


Link to post
Share on other sites

I know it is Excel with wich to open it, but couldn't get it to work.

Find a work around tho. :ph34r:

RunWait( @Comspec & " /c start C:\progra~1\VCG\Files\Templates\VCG.csv")
WinSetState("Microsoft Excel - VCG.csv", "", @SW_HIDE)

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

I know it is Excel with wich to open it, but couldn't get it to work.

<{POST_SNAPBACK}>

I think I know why that is. If you open the "Folder Options" dialog box from the explorer menu and look in the File Type associations, you can see that to open a csv file it uses "C:\Program Files\Microsoft Office\Office10\EXCEL.EXE" /e (note the /e in there.) Chances are good that will work without needing to pass through the command interperter.

Edit: Note: your program path may be different depending on where you installed office.

Edited by pekster

[font="Optima"]"Standing in the rain, twisted and insane, we are holding onto nothing.Feeling every breath, holding no regrets, we're still looking out for something."[/font]Note: my projects are off-line until I can spend more time to make them compatable with syntax changes.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0