cf 1.1: start file

  • Thread starter Christian Ropposch
  • Start date
C

Christian Ropposch

hello!

i use the compact framework 1.1 and i want to start a file with its
standard-application. (mostly a pdf.)

how can i do this with the cf 1.1? (process.start doesn't exist!)

thank you,
christian
 
P

Paul G. Tobey [eMVP]

Well, there is no such thing as .NET CF 1.1, but I'll assume that you mean
1.0. Look at OpenNETCF's Smart Device Framework, www.opennetcf.org.
There's code in there to create a better process class,
OpenNETCF.Diagnostics.Process.

Paul T.
 
S

Sergey Bogdanov

Yes, you can download SDF sources and take a look at how Process.Start
(with UseShellExecute) was implemented. You will see that it has
P/Invoke and one class, just integrate it to your project.


private sealed class ShellExecuteInfo
{
...
}

[DllImport("coredll.dll", EntryPoint="ShellExecuteEx", SetLastError=true)]
private extern static bool ShellExecuteEx( ShellExecuteInfo ex );
 
C

Christian Ropposch

thank you!

---
christian

Sergey said:
Yes, you can download SDF sources and take a look at how Process.Start
(with UseShellExecute) was implemented. You will see that it has
P/Invoke and one class, just integrate it to your project.


private sealed class ShellExecuteInfo
{
...
}

[DllImport("coredll.dll", EntryPoint="ShellExecuteEx", SetLastError=true)]
private extern static bool ShellExecuteEx( ShellExecuteInfo ex );



--
Sergey Bogdanov [.NET CF MVP, MCSD]
http://www.sergeybogdanov.com


Christian said:
is there another possibility? i only want to open a pdf-file! :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top