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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T01:46:07+00:00 2026-05-27T01:46:07+00:00

I’m fairly new to C#, however when I try to debug my program nothing

  • 0

I’m fairly new to C#, however when I try to debug my program nothing is shown. I have multiple forms and the first one is just a menu so I could go to the other forms.

This is my Form1.cs:

namespace EscapeLabryinth
{
    public partial class frmMainMenu : Form
    {
        frmGameMenu secondForm = new frmGameMenu();
        frmHowToPlay thirdForm = new frmHowToPlay();
        Music bgMusic;

        public frmMainMenu()
        {
            InitializeComponent();
        }

        private void btnPlay_Click(object sender, EventArgs e)
        {
            secondForm.Show();
            this.Hide();

        }

        private void btnInstru_Click(object sender, EventArgs e)
        {
            thirdForm.Show();
            this.Hide();
        }

        private void btnQuit_Click(object sender, EventArgs e)
        {
            Application.Exit();
        }

        private void btnAudio_Click(object sender, EventArgs e)
        {

        }

        private void frmMainMenu_Load(object sender, EventArgs e)
        {
            //Create a new Music object to play the background music
            bgMusic = new Music(Application.StartupPath + @"\resources\music\eurekaost.wav", true);

            bgMusic.LoopPlay();
            bgMusic.SetVolume(-100);

        }
    }
}

This is the same form’s designer:

namespace EscapeLabryinth
{
    partial class frmMainMenu
    {
        /// <summary>
        /// Required designer variable.
        /// </summary>
        private System.ComponentModel.IContainer components = null;

        /// <summary>
        /// Clean up any resources being used.
        /// </summary>
        /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
        protected override void Dispose(bool disposing)
        {
            if (disposing && (components != null))
            {
                components.Dispose();
            }
            base.Dispose(disposing);
        }

        #region Windows Form Designer generated code

        /// <summary>
        /// Required method for Designer support - do not modify
        /// the contents of this method with the code editor.
        /// </summary>
        private void InitializeComponent()
        {
            System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(frmMainMenu));
            this.btnQuit = new System.Windows.Forms.Button();
            this.lblTitleMenu = new System.Windows.Forms.Label();
            this.btnAudio = new System.Windows.Forms.Button();
            this.btnInstru = new System.Windows.Forms.Button();
            this.btnPlay = new System.Windows.Forms.Button();
            this.SuspendLayout();
            // 
            // btnQuit
            // 
            this.btnQuit.BackColor = System.Drawing.Color.Firebrick;
            this.btnQuit.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
            this.btnQuit.Font = new System.Drawing.Font("Hand Me Down S BRK", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.btnQuit.Location = new System.Drawing.Point(250, 290);
            this.btnQuit.Name = "btnQuit";
            this.btnQuit.Size = new System.Drawing.Size(150, 39);
            this.btnQuit.TabIndex = 2;
            this.btnQuit.Text = "Quit";
            this.btnQuit.UseVisualStyleBackColor = false;
            this.btnQuit.Click += new System.EventHandler(this.btnQuit_Click);
            // 
            // lblTitleMenu
            // 
            this.lblTitleMenu.AutoSize = true;
            this.lblTitleMenu.BackColor = System.Drawing.Color.Black;
            this.lblTitleMenu.Font = new System.Drawing.Font("Vindictive BRK", 21.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.lblTitleMenu.ForeColor = System.Drawing.Color.White;
            this.lblTitleMenu.Location = new System.Drawing.Point(83, 18);
            this.lblTitleMenu.Name = "lblTitleMenu";
            this.lblTitleMenu.Size = new System.Drawing.Size(532, 28);
            this.lblTitleMenu.TabIndex = 3;
            this.lblTitleMenu.Text = "Venture The Great Labryinth";
            // 
            // btnAudio
            // 
            this.btnAudio.BackgroundImage = global::EscapeLabryinth.Properties.Resources.speakers;
            this.btnAudio.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch;
            this.btnAudio.Location = new System.Drawing.Point(632, 355);
            this.btnAudio.Name = "btnAudio";
            this.btnAudio.Size = new System.Drawing.Size(54, 73);
            this.btnAudio.TabIndex = 4;
            this.btnAudio.UseVisualStyleBackColor = true;
            this.btnAudio.Click += new System.EventHandler(this.btnAudio_Click);
            // 
            // btnInstru
            // 
            this.btnInstru.BackColor = System.Drawing.Color.DarkSlateGray;
            this.btnInstru.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
            this.btnInstru.Font = new System.Drawing.Font("Hand Me Down S BRK", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.btnInstru.Location = new System.Drawing.Point(253, 190);
            this.btnInstru.Name = "btnInstru";
            this.btnInstru.Size = new System.Drawing.Size(150, 39);
            this.btnInstru.TabIndex = 5;
            this.btnInstru.Text = "How To Play";
            this.btnInstru.UseVisualStyleBackColor = false;
            this.btnInstru.Click += new System.EventHandler(this.btnInstru_Click);
            // 
            // btnPlay
            // 
            this.btnPlay.BackColor = System.Drawing.Color.Gold;
            this.btnPlay.FlatAppearance.BorderSize = 0;
            this.btnPlay.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
            this.btnPlay.Font = new System.Drawing.Font("Hand Me Down S BRK", 21.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.btnPlay.ForeColor = System.Drawing.Color.Black;
            this.btnPlay.Location = new System.Drawing.Point(250, 92);
            this.btnPlay.Name = "btnPlay";
            this.btnPlay.Size = new System.Drawing.Size(150, 39);
            this.btnPlay.TabIndex = 6;
            this.btnPlay.Text = "Venture!";
            this.btnPlay.UseVisualStyleBackColor = false;
            this.btnPlay.Click += new System.EventHandler(this.btnPlay_Click);
            // 
            // frmMainMenu
            // 
            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
            this.BackgroundImage = global::EscapeLabryinth.Properties.Resources.labyrinth;
            this.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch;
            this.ClientSize = new System.Drawing.Size(687, 437);
            this.Controls.Add(this.btnPlay);
            this.Controls.Add(this.btnInstru);
            this.Controls.Add(this.btnAudio);
            this.Controls.Add(this.lblTitleMenu);
            this.Controls.Add(this.btnQuit);
            this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
            this.Name = "frmMainMenu";
            this.Text = "Main Menu";
            this.Load += new System.EventHandler(this.frmMainMenu_Load);
            this.ResumeLayout(false);
            this.PerformLayout();

        }

        #endregion

        private System.Windows.Forms.Button btnQuit;
        private System.Windows.Forms.Label lblTitleMenu;
        private System.Windows.Forms.Button btnAudio;
        private System.Windows.Forms.Button btnInstru;
        private System.Windows.Forms.Button btnPlay;
    }
}

Please help 🙁

  • 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-05-27T01:46:08+00:00Added an answer on May 27, 2026 at 1:46 am

    First, you must have a program.cs or something similar that has a static void Main() defined.

    In this program.cs, you should have code that looks similar to this to get the application started and show the initial form:

    static class Program
    {
        /// <summary>
        /// The main entry point for the application.
        /// </summary>
        [STAThread]
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            Application.Run(new frmMainMenu());
        }
    }
    

    And finally, in your Project’s Properties, select the Application area and ensure that your Program class is selected in the Startup object dropdown.

    If all this is in place, then you are encountering an exception somewhere that you need to track down with a try/catch statement.

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

Sidebar

Related Questions

I have just tried to save a simple *.rtf file with some websites and
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
I'm making a simple page using Google Maps API 3. My first. One marker
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I have a jquery bug and I've been looking for hours now, I can't
this is what i have right now Drawing an RSS feed into the php,
I am reading a book about Javascript and jQuery and using one of the
I have a French site that I want to parse, but am running into
I want use html5's new tag to play a wav file (currently only supported
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this

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.