newbie question on Process.Start

Last post 05-16-2008 7:01 by redviking. 4 replies.
Page 1 of 1 (5 items)
Sort Posts: Previous Next
  • 07-23-2004 3:09

    newbie question on Process.Start

    Hi, i'm new to VB & OOP and I can't get this to work, can someone help me ?

    I added the reference and imported the namespace, but it doens't work, my app crashes. What am im doing wrong?

    Do i need to install dll's onto my handheld pc from OpenNETCF ???


    THX !!!



    Private Sub ButtonSituatieSchets_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ButtonSituatieSchets.Click
    ' Dim ODP_process As Object
    Dim ODP_process As New OpenNETCF.Diagnostics.Process
    ODP_process = OpenNETCF.Diagnostics.Process.Start("\windows\msreader.exe")
    End Sub
  • 07-23-2004 6:12 In reply to

    • ctacke
    • OpenNETCF Staff
    • Top 10 Contributor
    • Joined on 07-27-2007
    • Indiana
    • Posts 1,922

    Re: newbie question on Process.Start

    Saying it crashes is not useful. What exception exactly do you get?

    Also, the Process.Start method is static, so you shouldn't be creating a class instance to call it. Just call Process.Start(....)
  • 07-23-2004 7:53 In reply to

    Re: newbie question on Process.Start

    missingmethodexception
  • 07-23-2004 10:10 In reply to

    • ctacke
    • OpenNETCF Staff
    • Top 10 Contributor
    • Joined on 07-27-2007
    • Indiana
    • Posts 1,922

    Re: newbie question on Process.Start

    Sounds like the OpenNETCF libraries are not getting pushed to the device.
  • 05-16-2008 7:01 In reply to

    Re: newbie question on Process.Start

    I think my problem is similar. I have an VB app that checks to see is a particular app is running. That bit works fine.

    If the app is not running then it launches it (or is meant to) using process.start("\program files\myapp.exe", "")

    1. If I run the exe from the windows\system folder (the default folder that VS2005 IDE deploys to) it runs fine and the app(myapp.exe) is launched.

    2. If I run on the device from within the IDE it runs fine and the app(myapp.exe) is launched.

    3. If I move the exe (and the referenced OpenNetCF dll's) to the folder where I want it to run (which is the same folder as our main application) the exe appears to run (no errors are produced) however the app(myapp.exe) is not launched.

    This is beginning to drive me nuts. I can't figure out what is going wrong.

    Anybody have any thoughts, please? 

     

Page 1 of 1 (5 items)