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. Web Development
  3. ASP.NET
  4. covert the vb.net code to c#

covert the vb.net code to c#

Scheduled Pinned Locked Moved ASP.NET
csharphelpquestion
4 Posts 4 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.
  • K Offline
    K Offline
    kishorg1
    wrote on last edited by
    #1

    while (cnt < dsAllUpdtblData.Tables[0].Rows.Count - 1) { if(dsAllUpdtblData.Tables[0].Rows[cnt].Item[6].ToString()=="") { } cnt = cnt + 1; } i have above code in tht ....it will give an error to Item[6] this part how i will get perticulat column?

    A A D 3 Replies Last reply
    0
    • K kishorg1

      while (cnt < dsAllUpdtblData.Tables[0].Rows.Count - 1) { if(dsAllUpdtblData.Tables[0].Rows[cnt].Item[6].ToString()=="") { } cnt = cnt + 1; } i have above code in tht ....it will give an error to Item[6] this part how i will get perticulat column?

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

      It would really be useful to know what error - my mind reading is a bit off this morning.

      Bob Ashfield Consultants Ltd

      1 Reply Last reply
      0
      • K kishorg1

        while (cnt < dsAllUpdtblData.Tables[0].Rows.Count - 1) { if(dsAllUpdtblData.Tables[0].Rows[cnt].Item[6].ToString()=="") { } cnt = cnt + 1; } i have above code in tht ....it will give an error to Item[6] this part how i will get perticulat column?

        A Offline
        A Offline
        Abhishek Sur
        wrote on last edited by
        #3

        use dsAllUpdtblData.Tables["tablename"].Rows[cnt].Item["columnName"].ToString() instead of doing dsAllUpdtblData.Tables[0].Rows[cnt].Item[6].ToString() I think if you use columnname the problem will never arise...

        Abhishek Sur

        1 Reply Last reply
        0
        • K kishorg1

          while (cnt < dsAllUpdtblData.Tables[0].Rows.Count - 1) { if(dsAllUpdtblData.Tables[0].Rows[cnt].Item[6].ToString()=="") { } cnt = cnt + 1; } i have above code in tht ....it will give an error to Item[6] this part how i will get perticulat column?

          D Offline
          D Offline
          Dave Doknjas
          wrote on last edited by
          #4

          Just use "[6]" instead of ".Item[6]".

          David Anton http://www.tangiblesoftwaresolutions.com C++ to C# Converter C++ to VB Converter C++ to Java Converter VB & C# to Java Converter Java to VB & C# Converter Instant C#: VB to C# converter Instant VB: C# to VB converter Instant C++: convert VB, C#, or Java to C++/CLI

          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