kelly mort
Well-known Member
- Joined
- Apr 10, 2017
- Messages
- 2,169
- Office Version
- 2016
- Platform
- Windows
Hi,
I am looking for a script that will lookup data from my database based on the data entry in two textboxes.
I will enter data into the two textboxes then when I click the lookup button, I want it scan through the column containing the data and see if it can find those data in the two textboxes in database in such a way that they are in succession.
Now let me be clear here:
The data will be numbers in formats like;
01-02-03-04-05 and 06-07-08-09-10 these are the textbox entries
So look into the database and see if there is say;
60-02-43-20-03 in textbox1 and 06-07-11-32-70 in textbox2 . The order of the numbers does not matter. All that matters is that they are in succession with the data from first textbox on top and second textbox data below it. And also at least two numbers appear in each case.
I just wish it could be possible to do so.
So when the match is found, I will like to output the data to other textboxes. Here, there will be three of such:
1. To display match for textbox1
2. To display match for textbox 2
3. To display data below the display in the point (2) above
Since the database is a bit long, the match might be numerous a bit. That's there may be multiple matches. So in such cases, I will like to toggle between the result back and forth only if this is achievable.
I don't know if I should use message box instead of the textbox for the output display.
Let's take the data column to be B
I need your help, advice and others.
Thanks in advance
Kelly
I am looking for a script that will lookup data from my database based on the data entry in two textboxes.
I will enter data into the two textboxes then when I click the lookup button, I want it scan through the column containing the data and see if it can find those data in the two textboxes in database in such a way that they are in succession.
Now let me be clear here:
The data will be numbers in formats like;
01-02-03-04-05 and 06-07-08-09-10 these are the textbox entries
So look into the database and see if there is say;
60-02-43-20-03 in textbox1 and 06-07-11-32-70 in textbox2 . The order of the numbers does not matter. All that matters is that they are in succession with the data from first textbox on top and second textbox data below it. And also at least two numbers appear in each case.
I just wish it could be possible to do so.
So when the match is found, I will like to output the data to other textboxes. Here, there will be three of such:
1. To display match for textbox1
2. To display match for textbox 2
3. To display data below the display in the point (2) above
Since the database is a bit long, the match might be numerous a bit. That's there may be multiple matches. So in such cases, I will like to toggle between the result back and forth only if this is achievable.
I don't know if I should use message box instead of the textbox for the output display.
Let's take the data column to be B
I need your help, advice and others.
Thanks in advance
Kelly