Basic4ppc - Windows Mobile Development  

Go Back   Basic4ppc - Windows Mobile Development > Main Category > Questions & Help Needed
Home Register FAQ Members List Search Today's Posts Mark Forums Read

Questions & Help Needed Post any question regarding Basic4ppc.


Table with 2000 records. How to find with more speed?


Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 03-24-2008, 07:31 PM
Newbie
 
Join Date: Feb 2008
Posts: 1
Post Table with 2000 records. How to find with more speed?

Hello Friends.

My table have 1500 lines and 4 columns.

How to search a line in a table with more speed?

I'm using:

For i=0 to tbTable.RowCount-1
If tbTable.Cell( "MyKey" , i ) = sKey Then
...... My Code....
End If
Next

But it is too much slow.

Can you help me, please?

Thanks.

Sorry my poor english. I'm a Brazilian user.
Reply With Quote
  #2 (permalink)  
Old 03-24-2008, 07:36 PM
Erel's Avatar
Administrator
 
Join Date: Apr 2007
Posts: 3,199
Default

You should use the Filter method:
Code:
tbTable.Filter("MyKey = '" & sKey & "'")
For i=0 to tbTable.RowCount-1
    If tbTable.Cell( "MyKey" , i ) = sKey Then
       ...... My Code....
    End If
Next
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Renaming sorted records in table aerohost Questions & Help Needed 3 06-25-2008 05:54 PM
getting records alphabetically gjoisa Questions & Help Needed 2 05-10-2008 07:52 PM
Ticks as a floating point value on XP (not 2000) lancaster Questions & Help Needed 4 04-09-2008 11:38 AM
More than 2000 members on Basic4ppc forum Erel Forum Discussion 7 04-02-2008 07:18 PM
Speed grgczyz Basic4ppc Wishlist 3 05-31-2007 01:55 PM


All times are GMT. The time now is 03:37 AM.


Powered by vBulletin® Version 3.6.12
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.1.0