Launch program with Wine using .exe arguments

I have this program that I'm able to launch via command prompt in Windows or via a crafted .lnk when adding the specified arguments like this:

"C:\My\program.exe" /ID:"MyID" /CompanyID:"123" /TheAddr:"my.address.com"

By reading the documentation it seems that Wine interprets the arguments in the same way Windows does, and even when I'm certain that it is true for arguments presented in this way:

wine program.exe -my -arguments

It is not working for those arguments described above, maybe I'm missing some sort of escaping for some characters?

I've tried launching the application in this way:

wine program.exe /ID:"MyID" /CompanyID:"12" /TheAddr:"my.address.com"

But didn't worked, all I got was a generic error message from my program.

I believe that it is because I'm not passing the arguments the correct way, because if I craft a .lnk file in Windows updating its locations to match my Wine's prefix installation and then navigate to it via Wine's explorer.exe and double click on it, my program runs flawlessly.


Try this

exec wine "~/.wine/drive_c/My/program.exe" "-my"
  • The exec commands tell bash to morph into wine with the following arguments, so this is no longer bash running wine, but bash process becoming wine. The PID remains. You don't have two processes running.

The solution given to this question can be found on Unix.SE.

Transparently run wine programs