
Signature
Matt Campbell
mattc (at) saunatec [dot] com
> Hi All,
>
[quoted text clipped - 11 lines]
> me.memo1 = "TEXT 2"
> end if
I'll assume you would like at least one space between the old and the
new data.
If me.ckbox1 = -1 then
me.memo1 = Me.memo & " " & "TEXT 1"
end if
Here I'll assme a new line between the old and new data.
If me.ckbox2 = -1 then
me.memo1 = Me.memo & vbNewLine & "TEXT 2"
end if
Take your pick.

Signature
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail
mattc66 - 13 Mar 2007 22:57 GMT
That worked great. One more question if the user unchecks the box is there a
way to find and remove the text from the memo box?
>> Hi All,
>>
[quoted text clipped - 16 lines]
>
>Take your pick.

Signature
Matt Campbell
mattc (at) saunatec [dot] com
Anthos - 15 Mar 2007 00:48 GMT
I would do it like this.
Add this to each of the check box's on change event's.
Private Sub ckbox1_Click()
If Me.ckbox1 = -1 Then
Me.memo1 = Me.memo1 & " " & "TEXT 1"
Else
Me.memo1 = Left(Me.memo1.Value, (Len(Me.memo1.Value) - Len("TEXT
1")))
End If
End Sub
this would work if the "TEXT 1" was at the end of the memo field.
If the "TEXT 1" was at the begining, you would use the RIGHT function
isntead of the left.
Private Sub ckbox1_Click()
If Me.ckbox1 = -1 Then
Me.memo1 = "TEXT 1" & " " & Me.memo1
Else
Me.memo1 = Right(Me.memo1.Value, (Len(Me.memo1.Value) - Len("TEXT
1")))
End If
End Sub
Hope that helps.
Regards
Anthony
missinglinq - 15 Mar 2007 15:58 GMT
And if TEXT1 is in the middle of the field?
Me.Memo1 = Replace(Me.Memo1, Me.TEXT1, "")
Actually, I think that would work regardless of where it is in the string.

Signature
There's ALWAYS more than one way to skin a cat!
Answers/posts based on Access 2000