Can someone please instruct me how to create a separate routine that I call from various places (cmd click) to go out and determine the length of text in form fields. What I am doing is i want to go determine the length of form fields several times within a routine, but don't want to continue to repeat the logic over and over. when I return from this routine, i want to return to the line just under where i was.
thank you,
Here are the functions i want to perform several times over.
If IsNull(Me.TxtStreet) Then StreetLen = 0 Else StreetLen = Len(Me.TxtStreet)
If IsNull(Me.TxtAdd1) Then Add1Len = 0 Else Add1Len = Len(Me.TxtAdd1)
If IsNull(Me.TxtPObox) Then POBoxLen = 0 Else POBoxLen = Len(Me.TxtPObox)
If IsNull(Me.TxtAdd2) Then Address2Len = 0 Else Address2Len = Len(Me.TxtAdd2)
If IsNull(Me.TxtSuite) Then SuiteLen = 0 Else SuiteLen = Len(Me.TxtSuite)
thank you,
Here are the functions i want to perform several times over.
If IsNull(Me.TxtStreet) Then StreetLen = 0 Else StreetLen = Len(Me.TxtStreet)
If IsNull(Me.TxtAdd1) Then Add1Len = 0 Else Add1Len = Len(Me.TxtAdd1)
If IsNull(Me.TxtPObox) Then POBoxLen = 0 Else POBoxLen = Len(Me.TxtPObox)
If IsNull(Me.TxtAdd2) Then Address2Len = 0 Else Address2Len = Len(Me.TxtAdd2)
If IsNull(Me.TxtSuite) Then SuiteLen = 0 Else SuiteLen = Len(Me.TxtSuite)