VB Script onpostprompt S’abonner

0
Avatar
Pascal Lacasse

Hello,

After completing form i want to search for a value on excel sheet then enter this value on my label.

Thanks for helping me

Pascal

 

here is my code :

Sub findsomething()
Dim rng As Range
Dim account As String
Dim rownumber As Long

thc = Format.NamedSubStrings("#Lots").Value


Set rng = TableList("info").Columns("A:A").Find(What:=thc, _
LookIn:=xlFormulas, LookAt:=xlWhole, SearchOrder:=xlByRows, _
SearchDirection:=xlNext, MatchCase:=False, SearchFormat:=False)
rownumber = rng.Row
Format.NamedSubStrings("THC").Value = TableList("info").Cells(rownumber, 10).Value

End Sub

 

3 commentaires

0
Avatar
Pete Thane
Actions pour les commentaires Permalien

Cant you just use a database filter from the Database Setup screens and then link the entry box on your Data Entry Form to this? 

 

 

0
Avatar
Pascal Lacasse
Actions pour les commentaires Permalien

Hi, 

i'm currently using a DB connection for my record picker.

i want to select other information from another sheet then show 2 different information.

0
Avatar
Pete Thane
Actions pour les commentaires Permalien

So not sure, but I take it you can not join the two tables i the database connection setup or cannot use either the dropdown list or list box data entry options and so can configure the ODBC connection in there?

Vous devez vous connecter pour laisser un commentaire.