Hi Guys,
I’m calling outlook in a method, so someone sending mail to a person can automatically open up their outlook new message screen at the touch of a button. I can open Outlook without any problem, but using a commandline switch is proving to be quite the headache. Not being a programmer doesn’t help either.
however when I duplicate the command by enclosing the switch in quotes I get the error message.
It seems that the command line switch doesn’t like quotes and that’s how the executeProgram function is geared. Is there a way I can pass the parameter to the program without quotes?
I don’t know about outlook command line params, but when you call paths with spaces in Windows OS you need to enclose the in parenthesis, thus command line:
Thanks Miguel,
Thanks for the reply, which I tried, but got an illegal instruction error, generated by servoy.
If I just use the command to start Outlook, there is no problem - Outlook starts, but then the user has to click on new to start a new message.
It seems the executeProgram function passes the switch to outlook enclosed in quotes, which generates the error invalid command line switch, which is generated by outlook.
What I’m trying to do is strip the quotes from around the command line switch so it appears to Outlook as if it came from a command prompt window.
I think the problem is associated with the way windows does things versus the normal world, so this may not be a possibility.
where email is a var or field with the email address of the intended recipient ?
This way you have a fully cross-platform solution: showURL will open the default email client in Windows/MacOS/Linux. No problem if they are using Eudora or Mail or if Outlook is not installed in the standard path.[/code]
I fidled a bit more with it and the error message I get is always from the OS, not from Servoy. Looked around and found that we are misspeling the switch! Instead of: