S
Supra
i had usercontrol name doColor, then i added function procedure called
doColor. then i added module and called from method doColor into
module. the problem is i had to traced error:...
An unhandled exception of type 'System.NullReferenceException' occurred
in system.windows.forms.dll
Additional information: Object reference not set to an instance of an
object.
this coming from module method....
in module:
Sub DisplayMessage(ByVal rtb As RichTextBox, ByVal sText As String,
Optional ByVal Colour As String = "")
rtb.SelectionStart = rtb.Text.Length
'rtb.doColor(rtb, sText) <==== if i called docolor i got
error problem . but if i rem this....
rtb.SelectedText = sText <=== if i remmed above i got no problem
rtb.SelectionStart = rtb.Text.Length
rtb.ScrollToCaret()
sText = String.Empty
End Sub
i am trying to get irc chat working similar to mirc. but function of
doColor will worked on richextbox that embedded forecolour and
background colour. i had four mdichilds..if that is problem. this
code above will worked on small project i had no problem. i don't know
if my code above is accurate or not.
can ne 1 help me .
regards,
happy new yrs to every 1 >
doColor. then i added module and called from method doColor into
module. the problem is i had to traced error:...
An unhandled exception of type 'System.NullReferenceException' occurred
in system.windows.forms.dll
Additional information: Object reference not set to an instance of an
object.
this coming from module method....
in module:
Sub DisplayMessage(ByVal rtb As RichTextBox, ByVal sText As String,
Optional ByVal Colour As String = "")
rtb.SelectionStart = rtb.Text.Length
'rtb.doColor(rtb, sText) <==== if i called docolor i got
error problem . but if i rem this....
rtb.SelectedText = sText <=== if i remmed above i got no problem
rtb.SelectionStart = rtb.Text.Length
rtb.ScrollToCaret()
sText = String.Empty
End Sub
i am trying to get irc chat working similar to mirc. but function of
doColor will worked on richextbox that embedded forecolour and
background colour. i had four mdichilds..if that is problem. this
code above will worked on small project i had no problem. i don't know
if my code above is accurate or not.
can ne 1 help me .
regards,
happy new yrs to every 1 >
