Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. How to start application from sub main?

How to start application from sub main?

Scheduled Pinned Locked Moved Visual Basic
csharpquestionvisual-studiowpf
4 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • P Offline
    P Offline
    Pankaj Joshi
    wrote on last edited by
    #1

    Hello All, I have this simple question. When you write a application in VB 6. The application begins to execute from SUB MAIN. When you develop a form application using VISUAL STUDIO.NET, I dont see the SUB MAIN in the FORMS1.VB or anywhere else in the project. Is this SUB MAIN something created automatically by VB.NET and then compiled? I also create a module that have sub main() method but when I go the proprties of the project I'm unable to see the sub main in application startup drop down. Note: When I uncheck the check box "Enable Visual Styles" then I'm able to see the submain in dropdown ... if possible also let me know what that means???

    Regards Pankaj Joshi If you want to shape your dreams into reality, please wake-up...

    T 1 Reply Last reply
    0
    • P Pankaj Joshi

      Hello All, I have this simple question. When you write a application in VB 6. The application begins to execute from SUB MAIN. When you develop a form application using VISUAL STUDIO.NET, I dont see the SUB MAIN in the FORMS1.VB or anywhere else in the project. Is this SUB MAIN something created automatically by VB.NET and then compiled? I also create a module that have sub main() method but when I go the proprties of the project I'm unable to see the sub main in application startup drop down. Note: When I uncheck the check box "Enable Visual Styles" then I'm able to see the submain in dropdown ... if possible also let me know what that means???

      Regards Pankaj Joshi If you want to shape your dreams into reality, please wake-up...

      T Offline
      T Offline
      Thomas Stockwell
      wrote on last edited by
      #2

      You will have to google the subject. With VS2008, a new class file is automatically created with the sub main procedure, but you are definitely able to do so in pre-VS2008 editions. Be sure you look into the correct syntax for the method as well as their is an attribute that is attached to the main procedure.

      Regards, Thomas Stockwell Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning. Visit my Blog

      P 1 Reply Last reply
      0
      • T Thomas Stockwell

        You will have to google the subject. With VS2008, a new class file is automatically created with the sub main procedure, but you are definitely able to do so in pre-VS2008 editions. Be sure you look into the correct syntax for the method as well as their is an attribute that is attached to the main procedure.

        Regards, Thomas Stockwell Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning. Visit my Blog

        P Offline
        P Offline
        Pankaj Joshi
        wrote on last edited by
        #3

        Thanks for reply, But I'm asking about VS.NET 2005

        Regards Pankaj Joshi If you want to shape your dreams into reality, please wake-up...

        T 1 Reply Last reply
        0
        • P Pankaj Joshi

          Thanks for reply, But I'm asking about VS.NET 2005

          Regards Pankaj Joshi If you want to shape your dreams into reality, please wake-up...

          T Offline
          T Offline
          Thomas Stockwell
          wrote on last edited by
          #4

          The sub main procedure WILL work with VS2003, however VS2005, VS2008 simplify the process by creating a separate class file to divide the work. Google the topic for VS2003, but it WILL work.

          Regards, Thomas Stockwell Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning. Visit my Blog

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups