Greetings. Here's my situation: I have a library database containing hyphenated book numbers (TMINs). I often copy and paste these numbers into other programs. Some of these require the TMIN that I input to be hyphenated and some require it to be unhyphenated.
On my main publication info form, I have a button next to the TMIN that copies it (hyphens included) to the clipboard--works great. However, I would like a second button to copy it, but without the hyphens.
I know the hyphens can be removed with the Replace() function, but I'm not sure how to apply that to something that will not be displayed, only copied to the clipboard.
Here's the code for the button I have working (copies the TMIN as-is):
Private Sub BtnCopyTMIN_Click()
Me!FieldTMIN.SetFocus
DoCmd.RunCommand acCmdCopy
End Sub
Any ideas on how I can work the Replace() function in there, without changing my actual data? Thanks!