Results 1 to 8 of 8

Thread: load filed names into an array or counting no of fileds

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Feb 2001
    Location
    bkk
    Posts
    224

    load filed names into an array or counting no of fileds

    dear all
    how to know how many number of fileds are there in a table and i need all the field names loaded into an array. replies and help will be appreciated.
    thanks
    periyur

  2. #2
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170
    VB Code:
    1. msgbox objrs.Fields.Count
    2. 'Number of fields
    3.  
    4. For j = 0 To objrs.Fields.Count - 1
    5. strArr(j) = objrs.Fields(j).Name
    6. Next

  3. #3

    Thread Starter
    Addicted Member
    Join Date
    Feb 2001
    Location
    bkk
    Posts
    224
    thanks a lot mendhak, it was very helpful.

  4. #4
    Frenzied Member KayJay's Avatar
    Join Date
    Jul 2001
    Location
    Chennai
    Posts
    1,849
    Also take a look at the GETROWS method. Of course it retrieves the data as well.


    "Brothers, you asked for it."
    ...Francisco Domingo Carlos Andres Sebastian D'Anconia

  5. #5
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170
    YW.

  6. #6
    Frenzied Member KayJay's Avatar
    Join Date
    Jul 2001
    Location
    Chennai
    Posts
    1,849

    "Brothers, you asked for it."
    ...Francisco Domingo Carlos Andres Sebastian D'Anconia

  7. #7
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170
    Originally posted by KayJay
    Whaat? YW = You ******.

    Or You're Welcome, depends upon whether the glass is half full or half empty.

  8. #8
    Frenzied Member KayJay's Avatar
    Join Date
    Jul 2001
    Location
    Chennai
    Posts
    1,849
    LOL

    "Brothers, you asked for it."
    ...Francisco Domingo Carlos Andres Sebastian D'Anconia

Posting Permissions

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



Click Here to Expand Forum to Full Width