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. .NET (Core and Framework)
  4. Getting field type from database

Getting field type from database

Scheduled Pinned Locked Moved .NET (Core and Framework)
questiondatabasecomgraphicshelp
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.
  • K Offline
    K Offline
    KeesVer
    wrote on last edited by
    #1

    How can I detect whether a certain field retrieved from the database contains an image or other type of blob? I have a MSAccess table with an OLE-Object field holding a bitmap. This field is added to the DataTable as an System.Byte[] type. How do I know whether this field actually holds an bitmap? Thanks for any help you can give. Regards, Kees Vermeulen

    P 1 Reply Last reply
    0
    • K KeesVer

      How can I detect whether a certain field retrieved from the database contains an image or other type of blob? I have a MSAccess table with an OLE-Object field holding a bitmap. This field is added to the DataTable as an System.Byte[] type. How do I know whether this field actually holds an bitmap? Thanks for any help you can give. Regards, Kees Vermeulen

      P Offline
      P Offline
      Pete OHanlon
      wrote on last edited by
      #2

      The only way you can get this info is by inspecting the data in the field. You can either extract it and try to load it into an image or you can read the header bytes to see if they conform to known types.

      Deja View - the feeling that you've seen this post before.

      K 1 Reply Last reply
      0
      • P Pete OHanlon

        The only way you can get this info is by inspecting the data in the field. You can either extract it and try to load it into an image or you can read the header bytes to see if they conform to known types.

        Deja View - the feeling that you've seen this post before.

        K Offline
        K Offline
        KeesVer
        wrote on last edited by
        #3

        Thanks for your support.

        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