I'm flattered you like WebChat so much.
The Handles statement should be on the same line as the sub declaration.
Try this code:
Protected Sub WebChat1_Chatter(ByRef ChatText As String) Handles WebChat1.Chatter
System.Diagnostics.Debug.WriteLine("Page detected chatter event from WebChat control")
'The page will not be rendered
'after this event since it's a callback
'but ChatText will be displayed in the WebChat control.
'So you can replace bad words...
ChatText = ChatText.Replace("hell", "h***")
'...or spruce things up with emoticons
ChatText = ChatText.Replace(":)", _
"<img src='smiley.jpg' title=':)' />")
End Sub
As for the optimal way to filter a variety of words, well that's up to you to decide since the control doesn't directly implement that. I might suggest using one or more regular expressions to do the work. You may be able to find some useful regular expressions from google in case you're not very experienced with them.
You can set the WebChat's username property from the page load event or pretty much wherever else you want in the code behind.
WebChat1.UserName = sName
There is not currently a live content supervision feature built directly into the control, but you should be able to build one in yourself since all chat content gets filtered through the Chatter event. You could hook into this event and do pretty much any kind of filtering or supervision you want.

Signature
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net
> Hi, I just added Steve Orr's incredible WebChat control to my page (ASP.NET
> 2.0), but I'm not advanced enough to correctly add the additional code for
[quoted text clipped - 39 lines]
> Thank you very much in advance for any assistance! So sorry for the
> incredibly green questions. dma
dmitcha - 25 Jul 2006 17:15 GMT
Thanks, again, Steve; I gave both a shot, and unfortunately, neither works as
a cut-and-paste. I'm not clear enough on Visual Basic .NET commands to
figure out why the syntax errors keep popping up. The debugger wants the
Handles clause to have a "WithEvents variable defined in the containing type
or one of its base types." And unfortunately, I am getting a similar error
when I try to set the property in the Page Load event.
It seems that there will need to be some kind of Dim statement for WebChat1
for me to proceed, but I'm not even sure what kind of information I'm
handling here...
I'm guessing my list of requests is not even an hour's worth of work for
someone with experience (if I can just get the syntax for the filter list, I
can party on from there); is there anyone who might be able to tweak this
script remotely for a Peet's online Coffee Card or PayPal payment? Thank
you! dma
<%@ Page Language="VB" MasterPageFile="~/homepage.master" Title="Hollywood
Calls—Home" %>
<script runat="server">
Protected Sub LoginView1_ViewChanged(ByVal sender As Object, ByVal e As
System.EventArgs)
End Sub
Protected Sub NewUserLinkButton_Click(ByVal sender As Object, ByVal e As
System.EventArgs)
End Sub
Protected Sub WebChat1_Chatter(ByRef ChatText As String) Handles
WebChat1.Chatter
System.Diagnostics.Debug.WriteLine("Page detected chatter event from
WebChat control")
'The page will not be rendered
'after this event since it's a callback
'but ChatText will be displayed in the WebChat control.
'So you can replace bad words...
ChatText = ChatText.Replace("hell", "h***")
'...or spruce things up with emoticons
ChatText = ChatText.Replace(":)", "<img src='smiley.jpg' title=':)'
/>")
End Sub
</script>
> I'm flattered you like WebChat so much.
>
[quoted text clipped - 74 lines]
> > Thank you very much in advance for any assistance! So sorry for the
> > incredibly green questions
Well, I wasn't exactly expecting a response from you, yourself! Thank you
very much for the additional tips. Okay, going back in to try again. Please
be beyond flattered , Steve; I've been telling everyone today about this
amazing tool. You are BRILLIANT. dma