Length of field 
Author Message
 Length of field

  I want to export the ADO recordset to a text file delimited by space.
  I am trying to calculate the width of the field and the actual value and
pad with space accordingly in the text file.
  I don't know how to find the length of the field .  I tried using
rs.definedsize, but it always return 50 for varchar.

  Any help to do this or can somebody suggest a better way of exporting so
that the file also looks like a report with proper spaces.

anand V

Mon, 13 Oct 2003 06:12:43 GMT  
 Length of field
I think you want to be using the ActualSize property of the Field object.

Mon, 13 Oct 2003 08:28:03 GMT  
 [ 2 post ] 

 Relevant Pages 

1. way to find max var char field lengths of fields in SQL Server table

2. Length of fields

3. Variable Length Text Fields

4. Interesting question - VB4 - Any way to sort on length of field ??????????

5. Placing data in a fixed-length Binary field using ADO.

6. ADOX: Extending a fixed length Jet string field length

7. How to modify the field length from an access-field in Ms-VB

8. Capture actual field length from numeric fields

9. How to format the field's line's length according to the length of the Field's Value?

10. TableDef/Set all text fields to allow zero length

11. Allow Zero Length String in a field using SQL

12. limiting the length of a field with a return


Powered by phpBB® Forum Software