I've answered this in the technical group.

Cheers,
Jason S (a.k.a. iGadget)

"brandon" <brandonheng@hotmail.com> wrote in message
news:3dba8097$1@tnews.web.devx.com...
> i need to know how to pass a variable (eg. string) over to a handler. i

need
> the variable in order to perform some variable manipulation..
>
> here's a snippet of the code..
> --
> Dim msg As String = "hi, how are you?"
>
> --
>
> Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
> System.EventArgs) Handles Button1.Click
>
> Dim aTimer As System.Timers.Timer
>
> aTimer = New System.Timers.Timer()
>
> Dim cut As String = "you"
>
> AddHandler aTimer.Elapsed, AddressOf OnTimer()
>
> aTimer.Interval = 5000
>
> aTimer.Enabled = True
>
> End Sub
>
> ---
>
> Public Sub OnTimer(ByVal source As Object, ByVal e As ElapsedEventArgs)
>
> msg = Replace(msg, cut, "everyone")
>
> TextBox1.AppendText(msg)
>
> source.enabled = False
>
> End Sub
>
> ---
>
> how do i pass the 'cut' to the ontimer event?
> note that the timer may be called in different places.. and 'cut' may hold
> different values at a time
>
> hope u understand my poor english..
>
> sorry that i posted the thread here.. i need an answer urgently
>
> thanks,
> brandon
>
>
>
>