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. C#
  4. Creating a Windows form program using C# 8.0

Creating a Windows form program using C# 8.0

Scheduled Pinned Locked Moved C#
csharpasp-netquestionannouncement
12 Posts 5 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.
  • B Offline
    B Offline
    Brian_TheLion
    wrote on last edited by
    #1

    When using NET.Framework I can't find anyway of dragging objects to a form (eg textbox, button). When using NET.Core I can't find anyway of displaying the form so I can place objects on the form. All I get is the code for the form. Has there been some major changes to version 8.0 of C# which prevents me from doing certain things, such as dragging objects such as a button on to a form?

    L M Richard DeemingR 3 Replies Last reply
    0
    • B Brian_TheLion

      When using NET.Framework I can't find anyway of dragging objects to a form (eg textbox, button). When using NET.Core I can't find anyway of displaying the form so I can place objects on the form. All I get is the code for the form. Has there been some major changes to version 8.0 of C# which prevents me from doing certain things, such as dragging objects such as a button on to a form?

      L Offline
      L Offline
      Lost User
      wrote on last edited by
      #2

      You need to provide more information. When are you doing this, where are the objects being dragged from etc.? What part of the C# language do you believe is affecting this?

      B 1 Reply Last reply
      0
      • L Lost User

        You need to provide more information. When are you doing this, where are the objects being dragged from etc.? What part of the C# language do you believe is affecting this?

        B Offline
        B Offline
        Brian_TheLion
        wrote on last edited by
        #3

        On older version of c#. I could display the form on the screen and on the left side of the screen I had a list of tools such as button, textbox. I could then select an object from the list then drag it on the form and position it on the form where I wanted the object to appear (when I say object I mean things like buttons and textboxs). In C# 8.0 I don't seem to be able to do this unless you know of a way or something in the setup I need to change first.

        L D 2 Replies Last reply
        0
        • B Brian_TheLion

          On older version of c#. I could display the form on the screen and on the left side of the screen I had a list of tools such as button, textbox. I could then select an object from the list then drag it on the form and position it on the form where I wanted the object to appear (when I say object I mean things like buttons and textboxs). In C# 8.0 I don't seem to be able to do this unless you know of a way or something in the setup I need to change first.

          L Offline
          L Offline
          Lost User
          wrote on last edited by
          #4

          It is impossible to guess what you are doing. Please edit your original question above and add full details of the problem, including the failing code.

          1 Reply Last reply
          0
          • B Brian_TheLion

            On older version of c#. I could display the form on the screen and on the left side of the screen I had a list of tools such as button, textbox. I could then select an object from the list then drag it on the form and position it on the form where I wanted the object to appear (when I say object I mean things like buttons and textboxs). In C# 8.0 I don't seem to be able to do this unless you know of a way or something in the setup I need to change first.

            D Offline
            D Offline
            Dave Kreskowiak
            wrote on last edited by
            #5

            If you're talking about designing the from in Visual Studio, you can get the ToolBox to show up from the View menu. Just click the View menu, then Toolbox. Or you could hit Ctrl-W, X.

            Asking questions is a skill CodeProject Forum Guidelines Google: C# How to debug code Seriously, go read these articles.
            Dave Kreskowiak

            B 1 Reply Last reply
            0
            • B Brian_TheLion

              When using NET.Framework I can't find anyway of dragging objects to a form (eg textbox, button). When using NET.Core I can't find anyway of displaying the form so I can place objects on the form. All I get is the code for the form. Has there been some major changes to version 8.0 of C# which prevents me from doing certain things, such as dragging objects such as a button on to a form?

              M Offline
              M Offline
              Mycroft Holmes
              wrote on last edited by
              #6

              I think, and I may be wrong but is winforms supported in NET.Core? I believe the visual designer may not be included yet.

              Never underestimate the power of human stupidity - RAH I'm old. I know stuff - JSOP

              B 1 Reply Last reply
              0
              • D Dave Kreskowiak

                If you're talking about designing the from in Visual Studio, you can get the ToolBox to show up from the View menu. Just click the View menu, then Toolbox. Or you could hit Ctrl-W, X.

                Asking questions is a skill CodeProject Forum Guidelines Google: C# How to debug code Seriously, go read these articles.
                Dave Kreskowiak

                B Offline
                B Offline
                Brian_TheLion
                wrote on last edited by
                #7

                Hi Dave. I tried clicking on Toolbox in the View menu but when I do that the only thing I see on the screen is a list of tools. I need to have both the form and the list of tools displayed on the screen at the same time. In past versions of C# things were put in panels on the screen so the form display was put in one panel in the middle of the screen and the list of tools was put in the left side panel. Can panels be setup with C# 8.0 like they have been in the past for the user interface?

                D 1 Reply Last reply
                0
                • B Brian_TheLion

                  Hi Dave. I tried clicking on Toolbox in the View menu but when I do that the only thing I see on the screen is a list of tools. I need to have both the form and the list of tools displayed on the screen at the same time. In past versions of C# things were put in panels on the screen so the form display was put in one panel in the middle of the screen and the list of tools was put in the left side panel. Can panels be setup with C# 8.0 like they have been in the past for the user interface?

                  D Offline
                  D Offline
                  Dave Kreskowiak
                  wrote on last edited by
                  #8

                  Then you double-click the form you want to open. The Toolbox doesn't have a maximize button so it cannot be taking up the entire window. There is a small pushpin icon next to the Close (X) button in the ToolBox window. That can pin the toolbox window or allow it to autohide into a tab on the left edge of the Visual Studio window.

                  Asking questions is a skill CodeProject Forum Guidelines Google: C# How to debug code Seriously, go read these articles.
                  Dave Kreskowiak

                  B 1 Reply Last reply
                  0
                  • B Brian_TheLion

                    When using NET.Framework I can't find anyway of dragging objects to a form (eg textbox, button). When using NET.Core I can't find anyway of displaying the form so I can place objects on the form. All I get is the code for the form. Has there been some major changes to version 8.0 of C# which prevents me from doing certain things, such as dragging objects such as a button on to a form?

                    Richard DeemingR Offline
                    Richard DeemingR Offline
                    Richard Deeming
                    wrote on last edited by
                    #9

                    If you're running the current release of Visual Studio 2019, you'll need to enable the .NET Core Windows Forms designer in the "preview features" settings. It's still not complete, and there's a newer version available with the preview version of Visual Studio. Windows Forms Designer for .NET Core Released | .NET Blog[^] The .NET Framework version of the designer and toolbox should not have changed.


                    "These people looked deep within my soul and assigned me a number based on the order in which I joined." - Homer

                    "These people looked deep within my soul and assigned me a number based on the order in which I joined" - Homer

                    B 1 Reply Last reply
                    0
                    • D Dave Kreskowiak

                      Then you double-click the form you want to open. The Toolbox doesn't have a maximize button so it cannot be taking up the entire window. There is a small pushpin icon next to the Close (X) button in the ToolBox window. That can pin the toolbox window or allow it to autohide into a tab on the left edge of the Visual Studio window.

                      Asking questions is a skill CodeProject Forum Guidelines Google: C# How to debug code Seriously, go read these articles.
                      Dave Kreskowiak

                      B Offline
                      B Offline
                      Brian_TheLion
                      wrote on last edited by
                      #10

                      Thanks Dave. I found I had to dock some things such as toolbox so the interface becomes panels and is the way I want things to appear. Brian

                      1 Reply Last reply
                      0
                      • M Mycroft Holmes

                        I think, and I may be wrong but is winforms supported in NET.Core? I believe the visual designer may not be included yet.

                        Never underestimate the power of human stupidity - RAH I'm old. I know stuff - JSOP

                        B Offline
                        B Offline
                        Brian_TheLion
                        wrote on last edited by
                        #11

                        In that case I'll need to use only Net.Framework

                        1 Reply Last reply
                        0
                        • Richard DeemingR Richard Deeming

                          If you're running the current release of Visual Studio 2019, you'll need to enable the .NET Core Windows Forms designer in the "preview features" settings. It's still not complete, and there's a newer version available with the preview version of Visual Studio. Windows Forms Designer for .NET Core Released | .NET Blog[^] The .NET Framework version of the designer and toolbox should not have changed.


                          "These people looked deep within my soul and assigned me a number based on the order in which I joined." - Homer

                          B Offline
                          B Offline
                          Brian_TheLion
                          wrote on last edited by
                          #12

                          Thanks Richard. I updated Microsoft Visual Studio today and now have a form displayed when using Net.Core Brian

                          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