Create a paramter that will accept both Textbox and Richtextbox control

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

how can I make a parameter accept etiher richtextbox or textbox controls? currently My parameter is (ByVal txtBox as system.windows.form.textbox). This creates an error if the txtBox is of type RichTextBox.
 
Make the parameter type "Control", then in the method, be sure to validate
that the type is correct... (Control will allow any winform control, like a
progressbar)


Ed said:
how can I make a parameter accept etiher richtextbox or textbox controls?
currently My parameter is (ByVal txtBox as system.windows.form.textbox).
This creates an error if the txtBox is of type RichTextBox.
 
Back
Top