Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

CreateProcess - OpennetCF Diagnostic....

175 views
Skip to first unread message

A_PK

unread,
Apr 1, 2005, 3:18:03 AM4/1/05
to
Just wonder which one is better if I want to use them to Launch
Tmail.exe....

Could some one give me a sample code of how to use CreateProcess to launch
Tmail.exe.....
with the TO field filled with TO: sup...@xxx.com

thannk you very much


Alex Feinman [MVP]

unread,
Apr 1, 2005, 3:57:55 AM4/1/05
to
Actually, all you need is:
Process.Start("mailto:sup...@xxx.com")

--
Alex Feinman
---
Visit http://www.opennetcf.org
" A_PK" <pk...@hotmail.com> wrote in message
news:OJxoWNp...@TK2MSFTNGP15.phx.gbl...

Arun

unread,
Apr 1, 2005, 4:31:18 AM4/1/05
to
You can also try this,

CreateProcess("tmail.exe",
"mailto:sup...@xxx.com?subject=This is subject&body=messagebody");

Cheers,
Arun

PK

unread,
Apr 3, 2005, 10:57:17 PM4/3/05
to
Are there any dll that I should imports....

i type the whole string
CreateProcess("tmail.exe", "mailto:supp...@xxx.com?subjec­t=This is
subject&body=messagebody")

but the CreateProces got error........just wonder what thing should I
imports first.

Sergey Bogdanov

unread,
Apr 4, 2005, 12:25:14 AM4/4/05
to
Imports OpenNETCF.Diagnostics

and follow Alex's suggestion:

Process.Start("mailto:sup...@xxx.com")

For more information see:
http://www.opennetcf.org/SourceBrowse/view.aspx?f=d:/sites/OpenNETCF/InetPub/wwwroot/Source/OpenNETCF/Diagnostics/Process.cs

Best regards,
Sergey Bogdanov
http://www.sergeybogdanov.com


PK wrote:
> Are there any dll that I should imports....
>
> i type the whole string

> CreateProcess("tmail.exe", "mailto:supp...@xxx.com?subjec負=This is

PK

unread,
Apr 4, 2005, 3:33:30 AM4/4/05
to
thanks..it work...

just wonder is i want to get the subject and body filled as well ?

sorry .......i should have asked them all together...

Arun

unread,
Apr 4, 2005, 5:06:45 AM4/4/05
to
Hi,

Long back I have used CreateProcess in a sample, you need to try it
like this,

OpenNETCF.WinAPI.Core.CreateProcess("tmail.exe",
"mailto:supp...@xxx.com?subjec­t=This is subject&body=messagebody");

Try to check in Opennetcf sdf for any samples available.
Hope this helps,

Cheers,
Arun.
www.innasite.com

Sergey Bogdanov

unread,
Apr 4, 2005, 5:56:08 AM4/4/05
to
Arun,

Did you mean OpenNETCF.Win32.Core.CreateProcess instead of
OpenNETCF.WinAPI.Core.CreateProcess? If so it is an obsolete method and
must be replaced with OpenNETCF.Diagnostics.Process.Start.

Best regards,
Sergey Bogdanov
http://www.sergeybogdanov.com


Arun wrote:
> Hi,
>
> Long back I have used CreateProcess in a sample, you need to try it
> like this,
>
> OpenNETCF.WinAPI.Core.CreateProcess("tmail.exe",

> "mailto:supp...@xxx.com?subjec負=This is subject&body=messagebody");

Arun

unread,
Apr 4, 2005, 6:10:42 AM4/4/05
to
It was OpenNETCF.Win32.Core.createProcess, Thanks for the update
Sergey, Let me check with the change you suggested, but how can we add
message and subgect to tmail.exe using Process.Start
Thanks once again.
Cheers,
Arun.

Sergey Bogdanov

unread,
Apr 4, 2005, 6:25:21 AM4/4/05
to
In fact, Core.CreateProcess uses ProcessStartInfo together with
Process.Start:

ProcessStartInfo psi = new ProcessStartInfo();
psi.UseShellExecute = false;
psi.FileName = FileName;
psi.Arguments = CommandLine;
OpenNETCF.Diagnostics.Process.Start(psi);


Best regards,
Sergey Bogdanov
http://www.sergeybogdanov.com

Arun

unread,
Apr 4, 2005, 7:28:51 AM4/4/05
to
Thanks a lot Sergey.

A_PK

unread,
May 24, 2005, 1:36:26 AM5/24/05
to
Hi Sergery,

How about Attachment and Subject ? How could I attach my attachment, have a
Subject predefined ?
what is the command line look like ?

Process.Start("mailto:sup...@xxx.com?subject=Subjectg Tiltle&attachment
???or what ?

pls guide me....

"Sergey Bogdanov" <sergey....@gmail.com> wrote in message
news:OsB3J5M...@TK2MSFTNGP15.phx.gbl...


> Imports OpenNETCF.Diagnostics
>
> and follow Alex's suggestion:
>
> Process.Start("mailto:sup...@xxx.com")
>
> For more information see:
> http://www.opennetcf.org/SourceBrowse/view.aspx?f=d:/sites/OpenNETCF/InetPub/wwwroot/Source/OpenNETCF/Diagnostics/Process.cs
>
> Best regards,
> Sergey Bogdanov
> http://www.sergeybogdanov.com
>
>
> PK wrote:
>> Are there any dll that I should imports....
>>
>> i type the whole string

>> CreateProcess("tmail.exe", "mailto:supp...@xxx.com?subjec­t=This is

Sergey Bogdanov

unread,
May 24, 2005, 2:35:36 AM5/24/05
to
I believe, it's not possible to point an attachment in this way. What I
would suggest you is to get a small SMTP client and port it to CF.NET,
like this one:

http://spaces.msn.com/members/staceyw/Blog/cns!1pnsZpX0fPvDxLKC6rAAhLsQ!361.entry

--
Sergey Bogdanov
http://www.sergeybogdanov.com

0 new messages