Lets say i got couple Objects named as txt1 and another object as lbl1.
I have a function that should make changes on both of these objects, like highlighting.
I want to get the value of that object (doesnt matter which object) and than i want to highlight it.
Such as:
Function Highlight(Obj1 As Object, Obj2 As Object)
MyTxt = Obj1.Text
Obj1.Text = ""
Obj1.SetFocus
MyCap = Obj2.Caption
Obj2.Caption = ""
End Function
How can i achive that?
Objectdoes not have a.Textor.Captionproperty. Change your method to: