Click here to Skip to main content
15,900,973 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
Questionhndling of controls in smart device Pin
waquasalig29-May-08 22:55
waquasalig29-May-08 22:55 
QuestionRe: hndling of controls in smart device Pin
David Crow30-May-08 3:20
David Crow30-May-08 3:20 
Questionuser control Pin
subramanyeswari29-May-08 22:24
subramanyeswari29-May-08 22:24 
AnswerRe: user control Pin
subramanyeswari29-May-08 23:06
subramanyeswari29-May-08 23:06 
AnswerRe: user control Pin
ShilpiP29-May-08 23:50
ShilpiP29-May-08 23:50 
AnswerRe: user control Pin
David Crow30-May-08 3:21
David Crow30-May-08 3:21 
GeneralRe: user control Pin
subramanyeswari30-May-08 3:32
subramanyeswari30-May-08 3:32 
QuestionShellExecute swallowing empty parameter Pin
mav.northwind29-May-08 21:29
mav.northwind29-May-08 21:29 
Hi guys!

I got a really strange behaviour on one customer machine I really cannot figure out - perhaps someone can help...
A C++ plugin DLL of mine loaded into a third party application is calling one of my .NET applications using ShellExecute. Several arguments are passed along in this call, the last one being an empty string. Basically the call looks like this:
ShellExecute(AfxGetMainWnd()->GetSafeHwnd(), NULL, "C:\\Program Files\\MyApp\\MyApp.exe", "/arg1 /arg2 /arg3 \"argument3\" /arg4 \"\"", "C:\\Program Files\\MyApp", SW_SHOW);

/arg1 and /arg2 are simple flags for my .NET app, whereas /arg3 and /arg4 require an additional parameter. The parameter for /arg4 is supposed to be an empty string for this call.

The exact same version of this DLL works fine on many other machines, but on this particular one my .NET application won't start because it claims that the parameter for /arg4 is missing! I'm logging the arguments my application is called with and can see that the last parameter is missing, although the empty string is hard-coded inside the DLL and it works on every other machine I've come across so far.

What can be the reason for ShellExecute silently swallowing the last parameter?

Thanks in advance for every idea about how to proceed here...

Regards,
mav

--
Black holes are the places where God divided by 0...

QuestionRe: ShellExecute swallowing empty parameter Pin
David Crow30-May-08 3:25
David Crow30-May-08 3:25 
AnswerRe: ShellExecute swallowing empty parameter Pin
mav.northwind30-May-08 3:45
mav.northwind30-May-08 3:45 
QuestionRe: ShellExecute swallowing empty parameter Pin
David Crow30-May-08 4:08
David Crow30-May-08 4:08 
AnswerRe: ShellExecute swallowing empty parameter Pin
mav.northwind30-May-08 4:43
mav.northwind30-May-08 4:43 
QuestionRe: ShellExecute swallowing empty parameter Pin
David Crow30-May-08 4:50
David Crow30-May-08 4:50 
AnswerRe: ShellExecute swallowing empty parameter Pin
mav.northwind30-May-08 11:06
mav.northwind30-May-08 11:06 
QuestionOffice 2007 files in Webservice? Pin
ritz123429-May-08 21:27
ritz123429-May-08 21:27 
Questionhow to find out associated filetypes? Pin
steven_wong29-May-08 21:13
steven_wong29-May-08 21:13 
AnswerRe: how to find out associated filetypes? Pin
David Crow30-May-08 3:29
David Crow30-May-08 3:29 
AnswerRe: how to find out associated filetypes? Pin
ThatsAlok20-Jul-09 1:00
ThatsAlok20-Jul-09 1:00 
QuestionFile size in standard way Pin
CodingLover29-May-08 20:46
CodingLover29-May-08 20:46 
AnswerRe: File size in standard way Pin
Doc Lobster29-May-08 21:44
Doc Lobster29-May-08 21:44 
GeneralRe: File size in standard way Pin
CodingLover29-May-08 22:26
CodingLover29-May-08 22:26 
AnswerRe: File size in standard way Pin
CPallini29-May-08 22:06
mveCPallini29-May-08 22:06 
GeneralRe: File size in standard way Pin
CodingLover29-May-08 22:22
CodingLover29-May-08 22:22 
GeneralRe: File size in standard way Pin
CPallini29-May-08 22:34
mveCPallini29-May-08 22:34 
GeneralRe: File size in standard way Pin
CodingLover29-May-08 22:39
CodingLover29-May-08 22:39 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.