Results 1 to 5 of 5

Thread: dynamically adding rows to mshflexgrid

  1. #1

    Thread Starter
    PowerPoster Simply Me's Avatar
    Join Date
    Aug 2003
    Posts
    2,748

    dynamically adding rows to mshflexgrid

    Hi!. I have a mshflexgrid which has 2 rows. How will I add rows to it during run time? My user will have to type something in the text box. if the value in the textobx matches the one of the records
    in my DB then the resulting match will be displayed in the mshflexgrid's first row.

    My DB contains more than 10,000 records, so if the user will type 20 times in the textbox, i should have 20 rows displayed with records in it.

    BTW. i want the mshflexgrid to reset to 2 rows everyday. So if it has 20 rows today, the following morning it should have 2 rows again and cycle continues....

    Any help will be appreciated. Thank you.
    Last edited by Simply Me; Nov 20th, 2003 at 07:10 PM.
    To give is always to be NOBLE...
    To received is always to be BLESSED....
    Each day strive to be NOBLE
    Each day strive to be BLESSED

    If this post has helped you. Please take time to rate it.

    >=|+|=< Simply Me >=|+|=<

    ----------------------------------------
    Connection Strings | Number Only in Textbox | Splash Screen with Progress Bar | Printing to 1/2 of perforated bond paper |
    Freeze 2005 DataGridView Column

  2. #2

  3. #3

    Thread Starter
    PowerPoster Simply Me's Avatar
    Join Date
    Aug 2003
    Posts
    2,748
    Martin, could you be a little bit more specific? an example would be appreciated much. Thank you
    To give is always to be NOBLE...
    To received is always to be BLESSED....
    Each day strive to be NOBLE
    Each day strive to be BLESSED

    If this post has helped you. Please take time to rate it.

    >=|+|=< Simply Me >=|+|=<

    ----------------------------------------
    Connection Strings | Number Only in Textbox | Splash Screen with Progress Bar | Printing to 1/2 of perforated bond paper |
    Freeze 2005 DataGridView Column

  4. #4
    Former Admin/Moderator MartinLiss's Avatar
    Join Date
    Sep 1999
    Location
    San Jose, CA
    Posts
    33,431
    That is pretty specific. If you want the flexgrid to have a certain number of rows (like 99) you do

    MSFlexGrid1.Rows = 99

    or if you are reading records in a loop and you want to add rows one at a time you do

    MSFlexGrid1.Rows = MSFlexGrid1.Rows + 1

  5. #5

    Thread Starter
    PowerPoster Simply Me's Avatar
    Join Date
    Aug 2003
    Posts
    2,748
    my... im so sorry... thanks anyway
    To give is always to be NOBLE...
    To received is always to be BLESSED....
    Each day strive to be NOBLE
    Each day strive to be BLESSED

    If this post has helped you. Please take time to rate it.

    >=|+|=< Simply Me >=|+|=<

    ----------------------------------------
    Connection Strings | Number Only in Textbox | Splash Screen with Progress Bar | Printing to 1/2 of perforated bond paper |
    Freeze 2005 DataGridView Column

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