Discussion in 'Computer Programming, Emulation, and Game Modding' started by XabiPlayerPRO, Mar 12, 2017.

  1. XabiPlayerPRO

    XabiPlayerPRO Newbie

    I´m trying to open a file with an specific program from my program. I mean, I have a non-formatted file and I want to open it with WinRAR (it´s an example), but it only lets me to open the file and doesn´t let me to specify the program (in this case, WinRAR). Anybody can help me?
  2. Sammi Husky

    Sammi Husky GBAtemp Fan

    Jul 6, 2014
    United States
    As far as i'm aware, the easiest way would be to open the new process and make it open the file you want by passing the args to the new process as arguments. That is if the target app has functionality to open from CLI arguments. In which case you can specify the parameters when starting the process from within your app.

    The args of course would be the same as if you were running the target app from command prompt

    Something like
    Process p = new Process();
    p.StartInfo.FileName = App_To_Start;
    p.StartInfo.Arguments = Your_Args_Here;
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice