The best way to work with args for your winforms app is to use
string args = Environment.GetCommandLineArgs();
You can probably couple this with the use of an enum to solidify the use of the array througout your code base.
“And you can use this anywhere in your application, you aren’t just
restricted to using it in the main() method like in a console
- C# application both GUI and commandline
- How can I make the cursor turn to the wait cursor?
- How can I make a .NET Windows Forms application that only runs in the System Tray?
- Compiling/Executing a C# Source File in Command Prompt
- How to hide TabPage from TabControl [duplicate]
- How do you simulate Mouse Click in C#?
- Prompt Dialog in Windows Forms
- Binding an enum to a WinForms combo box, and then setting it
- Execute PowerShell Script from C# with Commandline Arguments
- How to bind a List to a ComboBox?
- Show control hierarchy in the WinForms designer
- DataGridView AutoFit and Fill
- How to store int array in application Settings
- App.config: User vs Application Scope
- How do I write a backslash (\) in a string?
- Hiding default gray column in datagridview winform
- How do I make an Event in the Usercontrol and have it handled in the Main Form?
- How can I call the Control color, I mean the default forms color?
- Override standard close (X) button in a Windows Form
- How to exit all running threads?
- Find node clicked under context menu
- Easiest way to change font and font size
- How to disable sort in DataGridView?
- How to make an installer for my C# application?
- C# Get a control’s position on a form
- Is it possible to Embed Gecko or Webkit in a Windows Form just like a WebView?
- How do I clear a combobox?
- Execute multiple command lines with the same process using .NET
- Event when a window gets maximized/un-maximized
- How do I remove the empty row from the bottom of a DataGridView control?
- How to make Combobox in winforms readonly
- Is it possible to use ShowDialog without blocking all forms?
- How can I make the image size smaller on a button?
- How to format DateTime columns in DataGridView?
- What is the best way to determine application root directory?
- C# Winforms bold treeview node doesn’t show whole text
- Does C# WinForms have a slider control?
- How to refresh DataSource of a ListBox
- Transparent background on winforms?
- Showing a Windows form on a secondary monitor?
- Hide Tab Header on C# TabControl
- How to simulate Windows shutdown for debugging?
- How do I put text on ProgressBar?
- How to set the first few characters of a WinForms TextBox to Read-Only?
- Get File Icon used by Shell
- How to update GUI with backgroundworker?
- Free/open source code editor UI control for .Net [closed]
- Making splitter visible for Split Panel
- How to Get a Specific Column Value from a DataTable?