Questions tagged [shellexecute]

ShellExecute is a Win32 API function used to launch document files

ShellExecute is a Microsoft Win32 API function used to launch document files.

Depending on the type of document file, it will do this through:

  • Creating a process using the executable file associated with the specified document
  • Using the COM subsystem to request a shell extension to launch the document
  • Initiating an action to be completed by the end-user, such as a search

As a rule of thumb, it can be assumed that invoking ShellExecute on a document file will have the same result as double-clicking on that file in Windows Explorer, including displaying user interface elements.

521 questions
0
votes
2 answers

C++ Running SHELLEXECUTEINFO and appending feature name

I dont know c++ and im having issues trying to append a string name to lpFile of SHELLEXECUTEINFO. I get a semi-colon delimited string from Installshield and then split it up and loop through it. I am trying to then append each one of the 'features'…
user616
  • 783
  • 4
  • 18
  • 44
0
votes
1 answer

When calling Win32 ShellExecute within ANY language, how can I stop program execution until ShellExecute is done?

This question is similar to most about ShellExecute, with one exception: I want to use ShellExecute because it's simple to use and it can be called with a few lines from within many programming languages including the now sunsetted Visual…
Jacob Bruinsma
  • 1,087
  • 1
  • 10
  • 23
0
votes
1 answer

.NET Process crashes but runs fine from explorer

I'm writing a small program which is to be used as a digital distribution platform for a specific game engine. This game engine has versions which are quite old and this seems to be causing some compatibility issues. Running a particular game seems…
Calin Leafshade
  • 1,195
  • 1
  • 12
  • 22
0
votes
1 answer

ShellExecute returns success, but does not execute file

I have a weird problem in one of my projects lately regarding the Win32 API ShellExecute() function. The program is compiled using Visual C++ 2015, in ANSI mode. int ret = (int)ShellExecuteA(0, "open", "C:\\Users\\Maverick\\stratum.jpg", NULL, NULL,…
0
votes
1 answer

Need to execute shell script from webapp and display console output in page

I am looking for java examples or library that will help me integrate this into a Struts2/Spring application. Many build systems such as Luntbuild or Hudson have this functionality, I thought I would ask if any one knows of a standalone example…
Bron
0
votes
2 answers

Jenkins Customize Editable Email Content

In my Jenkins step I have windows batch command which runs a java jar file (java -Dfile.encoding=UTF-8 -jar C:\Test1\Test.jar C:\Test\test.log) and output of which is a String value (verified Jenkins console the string is getting printed) . How will…
Harikrishnan R
  • 11
  • 1
  • 2
  • 10
0
votes
2 answers

Calling console app from IIS web service, not loading DLL's

My iis service is calling a console app. This console app references a DLL. When I check the error output I get this : Could not load file or assembly 'file:///c:\windows\system32\inetsrv\MyDll.dll' What is the correct way to call the…
JL.
  • 78,954
  • 126
  • 311
  • 459
0
votes
1 answer

ShellExecute in _beginthread

I need to run for example: ShellExecute(NULL, "open", "program.exe", NULL, NULL, SW_HIDE); as new thread, but I don't know how. I tried this: HANDLE hThread = (HANDLE) _beginthread(ShellExecute(NULL, "open", "program.exe", NULL, NULL, SW_HIDE), 0,…
Lukasz Re
  • 79
  • 1
  • 11
0
votes
1 answer

Setting windows system time in C++

I am having a GPS unit connected to com port. I wanted to make my system as a time server. How to do this? I tried using settime(), SetLocalTime(), SetSystemTime(), etc. None are working for me. By using system("cmd") I tried, but again I am not…
Anand MN
  • 1
  • 2
0
votes
1 answer

Opening a C# File with ProcessStartInfo opens wrong Visual studio Instance

I have a C# Code Analysis Application that opens C# using ProcessStartInfo And Process Start. It almost works. I want to use two instance of VS to perform the analysis: one to Debug the Analysis App, and another to have the File that is specified…
Mark Wardell
  • 493
  • 7
  • 25
0
votes
0 answers

Shellexecute mysql with command line to import a SQL file

If I type this into command window: "D:\databases\MySQL-5_0(x64)\bin\mysql.exe" -u root betting < "W:\data\projects\temp\example.sql" That works Next task is running above from my own computer program... 1) Using shellexecute directly to call mysql…
Tom
  • 3,587
  • 9
  • 69
  • 124
0
votes
1 answer

Start external program in it's directory

I need to start the external program c:\pro\prog1.exe from my project. The external program has its configuration file in the same directory c:\pro\prog1.ini. I do: ShellExecute(NULL,L"open",L"c:\pro\prog1.exe" ,NULL,NULL,SW_SHOWDEFAULT); Program…
vico
  • 17,051
  • 45
  • 159
  • 315
0
votes
4 answers

run gbak.exe by shellexecute in c++

I want to run gbak.exe file from my MFC application to backup firebird DB, i use this order but it didn't work: shellexecute(hwnd,"open","gbak.exe"," -user HAMED -password 1234 DB2.FDB b.fbk","",SW_SHOW); my problem is about gbak and firebird. can…
darya611
  • 1
  • 1
0
votes
1 answer

MysqlDump With ShellExecute Error

When I tried to execute mysqldump --host="ean13.info" --user="user" --password="mypass" info_upm > c:\\mysql.sql through ShellExecute in visual C++ I receive mysqldump ERROR: can not find table ">". Execution this command through command line…
0
votes
1 answer

ShellExecute(Ex) with 'properties' verb

I am trying to write a program, that opens the properties of a file, from the command-line. I read that it is possible to do, using either of the functions ShellExecute and ShellExecuteEx, with the 'properties' verb. So, I wrote such a C++ program…