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. BC30451: Name 'IsDBNull' is not declared.

BC30451: Name 'IsDBNull' is not declared.

Scheduled Pinned Locked Moved ASP.NET
help
3 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.
  • L Offline
    L Offline
    LeeOvEngland
    wrote on last edited by
    #1

    Hi, I am using a code behind and am trying to test for a null value using the code below: If Not IsDBNull(objDataReader("PrimaryContactTitle")) Then txtTitle.Text = objDataReader("PrimaryContactTitle") End If If I use the code directly on the aspx page it works fine. When I use it from the code behind it throws up the error: BC30451: Name 'IsDBNull' is not declared. I have imported all what I presume are the relevant namespaces System.Data System.Data.SqlClient I would appreciate any help with this problem Thanks Lee

    M 1 Reply Last reply
    0
    • L LeeOvEngland

      Hi, I am using a code behind and am trying to test for a null value using the code below: If Not IsDBNull(objDataReader("PrimaryContactTitle")) Then txtTitle.Text = objDataReader("PrimaryContactTitle") End If If I use the code directly on the aspx page it works fine. When I use it from the code behind it throws up the error: BC30451: Name 'IsDBNull' is not declared. I have imported all what I presume are the relevant namespaces System.Data System.Data.SqlClient I would appreciate any help with this problem Thanks Lee

      M Offline
      M Offline
      Marcie Jones
      wrote on last edited by
      #2

      Hi Lee, IsDBNull is in the Microsoft.VisualBasic namespace. Marcie http://www.codeproject.com

      L 1 Reply Last reply
      0
      • M Marcie Jones

        Hi Lee, IsDBNull is in the Microsoft.VisualBasic namespace. Marcie http://www.codeproject.com

        L Offline
        L Offline
        LeeOvEngland
        wrote on last edited by
        #3

        Thankyou Marcie

        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