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. problem in input

problem in input

Scheduled Pinned Locked Moved C#
helpquestion
8 Posts 6 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.
  • N Offline
    N Offline
    NiloofarNoroozi
    wrote on last edited by
    #1

    hi i have problem with this code objCommand.Parameters["@nopersoneli"].Value = Int32.Parse(vpost.txtNoPersoneli.Text); :error Input string was not in a correct format why? please help me

    W P P M N 5 Replies Last reply
    0
    • N NiloofarNoroozi

      hi i have problem with this code objCommand.Parameters["@nopersoneli"].Value = Int32.Parse(vpost.txtNoPersoneli.Text); :error Input string was not in a correct format why? please help me

      W Offline
      W Offline
      Wendelius
      wrote on last edited by
      #2

      Most likely you have illegal characters in vpost.txtNoPersoneli.Text

      The need to optimize rises from a bad design

      1 Reply Last reply
      0
      • N NiloofarNoroozi

        hi i have problem with this code objCommand.Parameters["@nopersoneli"].Value = Int32.Parse(vpost.txtNoPersoneli.Text); :error Input string was not in a correct format why? please help me

        P Offline
        P Offline
        Pedram Behroozi
        wrote on last edited by
        #3

        What is the type of objCommand? What is your vpost.txtNoPersonali.Text?

        N 1 Reply Last reply
        0
        • P Pedram Behroozi

          What is the type of objCommand? What is your vpost.txtNoPersonali.Text?

          N Offline
          N Offline
          NiloofarNoroozi
          wrote on last edited by
          #4

          txtNoPersoneli forexample=45

          P 1 Reply Last reply
          0
          • N NiloofarNoroozi

            txtNoPersoneli forexample=45

            P Offline
            P Offline
            Pedram Behroozi
            wrote on last edited by
            #5

            What is objCommand? It's possible that your objCommand.Parameters["@nopersoneli"].Value gets string and you get it an integer variable. and what is this "@" for?

            1 Reply Last reply
            0
            • N NiloofarNoroozi

              hi i have problem with this code objCommand.Parameters["@nopersoneli"].Value = Int32.Parse(vpost.txtNoPersoneli.Text); :error Input string was not in a correct format why? please help me

              P Offline
              P Offline
              Paul Conrad
              wrote on last edited by
              #6

              Most likely you have some type of invalid character in vpost.txtNoPersoneli.Text...

              "The clue train passed his station without stopping." - John Simmons / outlaw programmer "Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon "Not only do you continue to babble nonsense, you can't even correctly remember the nonsense you babbled just minutes ago." - Rob Graham

              1 Reply Last reply
              0
              • N NiloofarNoroozi

                hi i have problem with this code objCommand.Parameters["@nopersoneli"].Value = Int32.Parse(vpost.txtNoPersoneli.Text); :error Input string was not in a correct format why? please help me

                M Offline
                M Offline
                Mohammad Dayyan
                wrote on last edited by
                #7

                Hi. Please write your snippet code here.

                1 Reply Last reply
                0
                • N NiloofarNoroozi

                  hi i have problem with this code objCommand.Parameters["@nopersoneli"].Value = Int32.Parse(vpost.txtNoPersoneli.Text); :error Input string was not in a correct format why? please help me

                  N Offline
                  N Offline
                  nelsonpaixao
                  wrote on last edited by
                  #8

                  try

                  objCommand.Parameters.add["@nopersoneli"].Value = convert.toint32(txtNoPersoneli.Text);

                  nelsonpaixao@yahoo.com.br trying to help & get help

                  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