cancel
Showing results for 
Search instead for 
Did you mean: 

How to read data from file

PuneetSingh
Level 2
Hi, I am attaching a sheet. Need to know how to read Staff No, Name and NRIC No.
5 REPLIES 5

MetVonghiran
Level 4
Hi, singhpuneet.   Try the attachment file.   Regards, Met Vonghiran

PuneetSingh
Level 2
Thanks Sir, Actually here you were passing a hard coded cell value say Cell_Staff No  = C12 if in future this cell value changes then what. I am looking how to read this data dynamically is there any way. Thanks again for reply if there is any way then pls let me know.  

ArshuHansda
Level 4
You can use oledb excluding the empty rows. Thanks, Arshu

PuneetSingh
Level 2
If I am not wrong OLEDB is used for database. I want to read data from excel file which I attached.

StephenColeman
Level 4
You could try using the Excel VBO, searching for the cell value of ""Staff Number"" then using that to get the cell value of the cell containing the actual number. This would only work if the value of Staff Number is in a consistent place such as column C as you would find the wording of Staff Number in B12 so you would know to get the value in C12.  If you found Staff Number in B50, then the value should be in C50 and so on. Hopefully the attached picture will help.