Setting a font style to strikeout

Ricky D

Well-Known Member
Licensed User
Hi people.

I'd like to know how to set a textbox's font.style property to Strikeout and back to Regular.

I've tried this

B4X:
Sub btnL1_Click
   obj.New1(False)
   obj.FromControl("txtL1")
   If Line1Inline=True Then
      obj.SetProperty("Font.Style","Regular")
      Line1Inline=True
   Else
      obj.SetProperty("Font.Style","Strikeout")
      Line1Inline=False
   End If
End Sub
but I get this error

An error occurred in sub airport.btnL1_Click.
Line number: 387

Error description:
Object reference not set to an instance of an object.

Line 387 is the line with the Strikeout in it

regards, Ricky
 

Ricky D

Well-Known Member
Licensed User
thanks guys

i should have known this. my bad.

regards, Ricky
 
Top