Accessing DataType from ASP Page

Results 1 to 2 of 2

Thread: Accessing DataType from ASP Page

  1. #1
    Mike Harris Guest

    Default Accessing DataType from ASP Page

    How do I get a field&#039;s data type (not a number value respresenting the data type) to my ASP page using the adOpenSchema method (or should I be using another method)?<BR><BR>

  2. #2
    New ASP Guest

    Default RE: Accessing DataType from ASP Page

    Try this please:<BR><BR>DIM int_field_type<BR><BR>.... open db_conn here....<BR>.... open obj_rec here ...<BR><BR>int_field_type = VARTYPE(obj_rec.fields("the_field"))<BR><BR>respon se.write int_field_type<BR><BR>0 Empty (uninitialized) <BR>1 Null (no valid data) <BR>2 Integer <BR>3 Long integer <BR>4 Single-precision floating-point number <BR>5 Double-precision floating-point number <BR>6 Currency <BR>7 Date <BR>8 String <BR>9 Automation object <BR>10 Error <BR>11 Boolean <BR>12 Variant (used only with arrays of Variants) <BR>13 A data-access object <BR>17 Byte <BR>8192 Array <BR><BR>BUT: This type is NOT the type of your DB&#039;s field.<BR>It&#039;s the type that out-put to ASP page.<BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts