ant
July 2nd, 2001, 10:21 AM
I have a module with this code:
Sub insertfunc()
Dim func as string
Dim ch
Dim func2 as string
ch = Chr(10)
func = InputBox("Enter function name")
func2 = "function " & func & "()" & ch & "{" & ch & "" & ch & "}"
End Sub
I have that in a module because i'm going to use it on 7/8 different forms. In the form code, i want the user to be able to click a button and then the text of the variable func2 to be put in a richtextbox on that form. In the function itself i've tried richtextbox1.text = func2 because all the forms' richtextboxes are going to be called that. But when i do that it says object required. Someone help, please!!!
--Ant
--------------------------------------------------
check out my newest freeware
E-mail me at: christopherfolger@hotmail.com
for the address
Sub insertfunc()
Dim func as string
Dim ch
Dim func2 as string
ch = Chr(10)
func = InputBox("Enter function name")
func2 = "function " & func & "()" & ch & "{" & ch & "" & ch & "}"
End Sub
I have that in a module because i'm going to use it on 7/8 different forms. In the form code, i want the user to be able to click a button and then the text of the variable func2 to be put in a richtextbox on that form. In the function itself i've tried richtextbox1.text = func2 because all the forms' richtextboxes are going to be called that. But when i do that it says object required. Someone help, please!!!
--Ant
--------------------------------------------------
check out my newest freeware
E-mail me at: christopherfolger@hotmail.com
for the address