T
Tom
I have a 21 textboxes that opens up a popup form via a double-click. I then
enter text in the popup form... which -- when closed -- passes the
information into the textbox.
Currently, the textboxes (controlnames = Comment1 to Comment21) are visible
but I don't show all of the text (it's only about 1 inch wide).
So, here's what I'm hoping to do...
- hide the textboxes that call the popup via double-click
- add a double-click event to their adjacent combo box (controlnames =
Frame1 to Frame21). The combos will remain visible.
- the combo's double-click will "execute" (double-click) the hidden
textboxes
- hence it will appear that the combo boxes bring up the popup
Here's what I have done so far:
- added "=CallPopUp()" to all of the 21 combos "Double-Click" (in the
properties window)
- added the function below... Frame1 to Frame9 have a controlname length of
6; Frame10 to 21 have a length of 7.
- so, when double-clicking on Frame1 to Frame 9, I get the message "Hello -
1"; otherwise I get "Hello - 2".
Okay, here's what I need some help with:
- I need to replace the "Hello" message with some code that will
"doubleclick" let's say Comment1. (I'll deal with the proper comment box
later).
- I replaced the msgbox with "Call Comment1_DblClick"... that didn't seem to
work.
So my question, how do I properly "call" the double-click of another
control?
Thanks,
Tom
==============================
Function CallPopUp() As Boolean
Dim ctl As Control
Dim FieldName As String, FieldName1 As String
Set ctl = Screen.ActiveControl
If Len(ctl.Name) = 6 Then
FieldName1 = "Comment" & Right(ctl.Name, 1)
MsgBox "Hello - 1"
'Comment1_DblClick
ElseIf Len(ctl.Name) = 7 Then
FieldName1 = "Comment" & Right(ctl.Name, 2)
MsgBox "Hello - 2"
End If
Set ctl = Nothing
End Function
==============================
enter text in the popup form... which -- when closed -- passes the
information into the textbox.
Currently, the textboxes (controlnames = Comment1 to Comment21) are visible
but I don't show all of the text (it's only about 1 inch wide).
So, here's what I'm hoping to do...
- hide the textboxes that call the popup via double-click
- add a double-click event to their adjacent combo box (controlnames =
Frame1 to Frame21). The combos will remain visible.
- the combo's double-click will "execute" (double-click) the hidden
textboxes
- hence it will appear that the combo boxes bring up the popup
Here's what I have done so far:
- added "=CallPopUp()" to all of the 21 combos "Double-Click" (in the
properties window)
- added the function below... Frame1 to Frame9 have a controlname length of
6; Frame10 to 21 have a length of 7.
- so, when double-clicking on Frame1 to Frame 9, I get the message "Hello -
1"; otherwise I get "Hello - 2".
Okay, here's what I need some help with:
- I need to replace the "Hello" message with some code that will
"doubleclick" let's say Comment1. (I'll deal with the proper comment box
later).
- I replaced the msgbox with "Call Comment1_DblClick"... that didn't seem to
work.
So my question, how do I properly "call" the double-click of another
control?
Thanks,
Tom
==============================
Function CallPopUp() As Boolean
Dim ctl As Control
Dim FieldName As String, FieldName1 As String
Set ctl = Screen.ActiveControl
If Len(ctl.Name) = 6 Then
FieldName1 = "Comment" & Right(ctl.Name, 1)
MsgBox "Hello - 1"
'Comment1_DblClick
ElseIf Len(ctl.Name) = 7 Then
FieldName1 = "Comment" & Right(ctl.Name, 2)
MsgBox "Hello - 2"
End If
Set ctl = Nothing
End Function
==============================