Link to home
Start Free TrialLog in
Avatar of Aurokripa
Aurokripa

asked on

Macro in Visual Basic

To_Experts

I have a problem regarding macro which i described
below.Here i retrieve fieldname from array.
e.g.-> "SR_NO" is fieldname

coding:

Dim TempStoreNumber As Integer
Dim NumberOfArray As Integer
dim rsiled as recordset

For TempStoreNumber = 0 To NumberOfArray
 With rsiled
  X1 = "!" + TempArrayfieldname(TempStoreNumber)
  MSFlexGrid1.TextMatrix(1,TempStoreNumber) = " " & X1 & " "
 End With
Next
      
Points:

 1) I got x1 = "!SR_NO"  
 2) I got msflexgrid1.textmatrix(1,TempStoreNumber)="!SR_NO"            

Both are same.Actually in first point i got correct value(field name).
But in second point i want value of that value(means fieldname's value).

I want the value of "SR_NO" (Fieldname of a table) from table.
which i want to pass in msflexgrid which i mentioned below.

   msflexgrid1.textmatrix(1, TempStoreNumber) =


Please reply us with full coding.

with warm regards,
Bhavesh Patel
ASKER CERTIFIED SOLUTION
Avatar of batdan
batdan

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial