T
thebridge
Hi,
When I pass a value from MyTextBox to MyComboBox using:
Me.MyTextBox = Me.MyComboBox
It does Not trigger the AfterUpdate Event of the ComboBox
I need it to! Any Suggestions??
I have tried: copy and pasting by but that creates a problem
Me.MyTextBox = BarCodeData$ 'passes the variable value to MyTextBox
Me.MyTextBox .SetFocus
Me.MyTextBox .SelStart = 0
Me.MyTextBox .SelLength = Len(Me.MyTextBox ) + 1
SendKeys "^c" 'copies the value of of MyTextBox
as soon as I add the below line, it no longer copies the value in
MyTextBox
Me.MyComboBox.SetFocus
The onEnter Event of MyComboBox has the following code that works fine.
Private Sub cboLookupPart_Enter()
Me.MyComboBox.SetFocus
Me.MyComboBox.SelStart = 0
Me.MyComboBox.SelLength = Len(Me.MyComboBox.Text)
SendKeys "^v"
End Sub
If I ran all the code above, all works but the "Copy" and thus anything
that may be in the clipboard is pasted into MyComboBox, and the
AfterUpDate of MyComboBox triggers.
I know that there are compelling reason NOT to use the SendKeys but I
was just trying something
What I'd really like to do is eliminate MyTextBox and pass the Variable
directly to MyComboBox:
Me.MyComboBox= BarCodeData$
And have it force the AfterUpdate Event of MyComboBox
Eagerly awaiting suggestions!
Thank you,
Robert Bloomfield
When I pass a value from MyTextBox to MyComboBox using:
Me.MyTextBox = Me.MyComboBox
It does Not trigger the AfterUpdate Event of the ComboBox
I need it to! Any Suggestions??
I have tried: copy and pasting by but that creates a problem
Me.MyTextBox = BarCodeData$ 'passes the variable value to MyTextBox
Me.MyTextBox .SetFocus
Me.MyTextBox .SelStart = 0
Me.MyTextBox .SelLength = Len(Me.MyTextBox ) + 1
SendKeys "^c" 'copies the value of of MyTextBox
as soon as I add the below line, it no longer copies the value in
MyTextBox
Me.MyComboBox.SetFocus
The onEnter Event of MyComboBox has the following code that works fine.
Private Sub cboLookupPart_Enter()
Me.MyComboBox.SetFocus
Me.MyComboBox.SelStart = 0
Me.MyComboBox.SelLength = Len(Me.MyComboBox.Text)
SendKeys "^v"
End Sub
If I ran all the code above, all works but the "Copy" and thus anything
that may be in the clipboard is pasted into MyComboBox, and the
AfterUpDate of MyComboBox triggers.
I know that there are compelling reason NOT to use the SendKeys but I
was just trying something
What I'd really like to do is eliminate MyTextBox and pass the Variable
directly to MyComboBox:
Me.MyComboBox= BarCodeData$
And have it force the AfterUpdate Event of MyComboBox
Eagerly awaiting suggestions!
Thank you,
Robert Bloomfield