I have some app that i need to call and pass some params to it. I tried this with cmd and it worked but somehow ShellExecute doesn't pass params to my app. I can't see where is my problem:
Path and file names are valid!!! I tried it with cmd and it works, but with this my app is started and expects inout but it should grab it from file as it was specified by params, but obviously not passed at all.
Looks like ShellExecute cant handle file redirection ('<' , '>'), so i tried to crate bat file, but the problem is that i use tstring:
1 2 3 4 5
typedef std::basic_string<TCHAR> tstring;
...
tstring commands;
commands = ....// fill this
fwrite(commands.c_str(), sizeof(TCHAR), commands.size(), f);
and then call that with ShellExecute but it won't work:
'C' is not recognized ....bla...bla
, until i resaved it manually as ANSI text file and then it works???
Does "bat" files "supports" Unicode chars when reading?
I tried writing BOM at begining ("\xfffe") but does not work either.