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 7870893
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T01:44:44+00:00 2026-06-03T01:44:44+00:00

I have a Windows application written in C# using winforms. I want to make

  • 0

I have a Windows application written in C# using winforms. I want to make sure that whenever someone starts it from any other application using process.start the UI is not shown and the application should start silently.

I do not have control over other applications so I can not use:

var p = new Process();
p.StartInfo = new ProcessStartInfo(); 
p.StartInfo.UseShellExecute = true; 
p.StartInfo.WorkingDirectory = ConfigurationManager.AppSettings["exeFolder"].ToString(); p.StartInfo.WindowStyle = ProcessWindowStyle.Normal; 
p.StartInfo.FileName = ConfigurationManager.AppSettings["exeName"].ToString(); 
p.Start();
  • 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-03T01:44:47+00:00Added an answer on June 3, 2026 at 1:44 am

    Thanks for your replies. I am sorry to not have provided my solution earlier. I have resolved the problem and have documented the solution for someone else to use in future.

    You can find the solution here.

    How To
    · Create a new windows project and delete the default form (Form1).
    · In Program.cs create a new class and inherit it from Form.
    · Please refer the code below.
    · Now change the Main method. In Application.Run change the startup object from Form1 to ApplicationStartUp.

    using System;
    using System.Drawing;
    using System.Windows.Forms;
    using BackgroundApp.Properties;
    
    namespace BackgroundApp
    {
        static class Program
        {
            /// <summary>
    
    
       /// The main entry point for the application.
        /// </summary>
        [STAThread]
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            Application.Run(new ApplicationStartUp());
        }
    }
    
    public class ApplicationStartUp : Form
    {
        private NotifyIcon trayIcon;
        private ContextMenu trayMenu;
    
        private void InitializeComponent()
        {
            trayMenu = new ContextMenu();
            trayMenu.MenuItems.Add("Exit", OnExit);
            trayIcon = new NotifyIcon();
            trayIcon.Text = Resources.TrayIcon;
            trayIcon.Icon = new                            Icon(global::BackgroundApp.Properties.Resources.IntegratedServer, 40, 40);
            trayIcon.ContextMenu = trayMenu;
            trayIcon.Visible = true;
        }
    
        //Ctor
        public ApplicationStartUp()
        {
            InitializeComponent();
        }
    
        protected override void OnLoad(EventArgs e)
        {
            Visible = false;
            ShowInTaskbar = false;
            base.OnLoad(e);
        }
    
        private void OnExit(object sender, EventArgs e)
        {
            // Release the icon resource.
            trayIcon.Dispose();
            Application.Exit();
        }
    
        protected override void Dispose(bool isDisposing)
        {
            if (isDisposing)
            {
                // Release the icon resource.
                trayIcon.Dispose();
            }
            base.Dispose(isDisposing);
        }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have written a basic Application for windows mobile 5. It is using visual
I have a Windows application written in C++ that occasionally evaporates. I use the
We have a Windows desktop application written in Delphi that works fine on Windows
I have a Windows Workflow application that uses classes I've written for COM automation.
I have a Windows Mobile application written in Java that uses AWT for the
I have a Windows mobile 4.0 application, written using EVC++ 4.0 SP4 with MFC,
I have an application written in Delphi 2006 that was working fine in Windows
I have an application written on Java running on the machine (Linux/Windows). I want
I have written a Chat application using C#. The project is a separate Windows
I have a distributed windows application (written in C#) that currently uses MSDE. The

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.