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
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. C#
  4. Auto Generate Customer ID

Auto Generate Customer ID

Scheduled Pinned Locked Moved C#
csharpdatabasesql-serversysadminsales
8 Posts 5 Posters 1 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.
  • N Offline
    N Offline
    nt_virus
    wrote on last edited by
    #1

    Hello Is there any way to generate automatic customer id in c# windows form. Backend will be SQL Server..

    A N V 3 Replies Last reply
    0
    • N nt_virus

      Hello Is there any way to generate automatic customer id in c# windows form. Backend will be SQL Server..

      A Offline
      A Offline
      AhsanS
      wrote on last edited by
      #2

      Make a datatable. Make the customer id field primary key and set its autoincrement property to true.

      Ahsan Ullah Senior Software Engineer

      1 Reply Last reply
      0
      • N nt_virus

        Hello Is there any way to generate automatic customer id in c# windows form. Backend will be SQL Server..

        N Offline
        N Offline
        N a v a n e e t h
        wrote on last edited by
        #3

        nt_virus wrote:

        Backend will be SQL Server..

        Use identity column for customer id.

        Navaneeth How to use google | Ask smart questions

        1 Reply Last reply
        0
        • N nt_virus

          Hello Is there any way to generate automatic customer id in c# windows form. Backend will be SQL Server..

          V Offline
          V Offline
          V 0
          wrote on last edited by
          #4

          generate a GUID

          V.
          Stop smoking so you can: Enjoy longer the money you save. Moviereview Archive

          S 1 Reply Last reply
          0
          • V V 0

            generate a GUID

            V.
            Stop smoking so you can: Enjoy longer the money you save. Moviereview Archive

            S Offline
            S Offline
            sumit7034
            wrote on last edited by
            #5

            Can u provide a sample code to generate GUID?

            N 1 Reply Last reply
            0
            • S sumit7034

              Can u provide a sample code to generate GUID?

              N Offline
              N Offline
              N a v a n e e t h
              wrote on last edited by
              #6

              GUID.NewGUID()

              Navaneeth How to use google | Ask smart questions

              S 1 Reply Last reply
              0
              • N N a v a n e e t h

                GUID.NewGUID()

                Navaneeth How to use google | Ask smart questions

                S Offline
                S Offline
                sumit7034
                wrote on last edited by
                #7

                Thanks

                V 1 Reply Last reply
                0
                • S sumit7034

                  Thanks

                  V Offline
                  V Offline
                  V 0
                  wrote on last edited by
                  #8

                  Try googling or MSDN once in a while, you could have found it in 5 minutes if you tried... :-)

                  V.
                  Stop smoking so you can: Enjoy longer the money you save. Moviereview Archive

                  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