Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7829403
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T10:44:46+00:00 2026-06-02T10:44:46+00:00

I have a question regarding launching an external application from an asp.net website. Now

  • 0

I have a question regarding launching an external application from an asp.net website. Now I think there are security measures in place to prevent that and I know it’s not a good practice, but for an intranet site I’m developing it would be incredibly handy to be able to do that.

So far I’ve found where I can launch an external app if I’m running my server locally (in debug) then it works fine. When I publish the files out to my webserver it no longer works. I know my filepaths are going to be different I imagine, but how can I check if a local file exists? Or can I?

So here’s my code:

//the actual launch button on the page
protected void btnLaunchTnet_Click(object sender, EventArgs e)
{
    string tnetpath = "c:\path\tnet.exe";      
    RunProcess(tnetpath, "");
}


private void RunProcess(string cmd, string arguments)
{
    System.Diagnostics.Process p;
    p = new System.Diagnostics.Process();

    p.StartInfo.FileName = cmd;

    if (arguments.Length > 1)
    {
        p.StartInfo.Arguments = arguments;
    }
    p.StartInfo.WindowStyle = System.Diagnostics.ProcessWindowStyle.Hidden;
    p.StartInfo.RedirectStandardOutput = false;
    p.StartInfo.UseShellExecute = false;
    p.Start();
}

I also have a quick ‘check if this file exists’ that I use to disable or enable the button that launches the app

private bool CheckFileExists(string filepath)
{
    FileInfo SetupPath = new FileInfo(filepath);
    return SetupPath.Exists;
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-02T10:44:46+00:00Added an answer on June 2, 2026 at 10:44 am

    I know of a way using ActiveX controls, but then it would work only with Internet Explorer.

    Check out this post.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have question regarding associations in Ruby on Rails. In the application there are
I have a question regarding handling errors in a J2EE application. Our current application
Have a question regarding something which has been bugging me for some time now.I'm
I have a question regarding Google Docs and content controls (if there are any?)
I have a question regarding the threads that my application spawns during execution and
I have a question regarding using LightSpeed in a MVC3 Web application. I am
I have a question regarding some JavaScript, there is a big picture and the
I have a question regarding the performance of an application. I have an object
I have a question regarding launching new activities. It boils down to this. I
I have a question regarding parsing data from Wikipedia for my Android app. I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.