Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Problem with string in Formula

Status
Not open for further replies.

JenA

MIS
Jul 11, 2003
1
US
I declared varName as string and use it in formula:
crystalReport1.SelectionFormula="{Item.ItemName}=" & varName
I get "Error in formula"
Formula in Designer works but in VB not.
varName=cboName.text
CrystalReport 4.6 and VB6
 


Try this:

crystalReport1.SelectionFormula="{Item.ItemName}='" & varName & "'"
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top