We have about 15 text boxex with numbers load from SQL database. Users wanted: If all fields are zeros they want the fields blank. I try to set txt.text = "" but got type mismatch error. I am thinking: If I can match the text color fields to the background of the text boxes if they are all zeros, it should work. My questions: will it work if text color match with text box background? and How do I set text color = white to make it match with text box background?
Here are sample of my codes:
If Me.txtAct2Back = "0" And Me.txtAct1Back = "0" And _
Me.txtActBRD = "0" And Me.txtActNow = "0" And _
Me.txtActProj = "0" And Me.txtBud2Back = "0" then _
Me.txtAct2Back = ? And Me.txtAct1Back = ? And _
Me.txtActBRD = ? And Me.txtActNow = ? And _
Me.txtActProj = ? And Me.txtBud2Back = ?
End if
Thanks,
Khanh
Here are sample of my codes:
If Me.txtAct2Back = "0" And Me.txtAct1Back = "0" And _
Me.txtActBRD = "0" And Me.txtActNow = "0" And _
Me.txtActProj = "0" And Me.txtBud2Back = "0" then _
Me.txtAct2Back = ? And Me.txtAct1Back = ? And _
Me.txtActBRD = ? And Me.txtActNow = ? And _
Me.txtActProj = ? And Me.txtBud2Back = ?
End if
Thanks,
Khanh