C# to VB Translation

Discussion in 'ASP .Net' started by Jim Heavey, Dec 2, 2003.

  1. Jim Heavey

    Jim Heavey Guest

    I found and example on the web where a event for a customValidator is being
    loaded in code. It looks like the following..

    this.CustomValidator1.ServerValidate +=
    new System.Web.UI.WebControls.ServerValidateEventHandler(
    this.CustomValidator1_ServerValidate);
    this.Load += new System.EventHandler(this.Page_Load);

    I thought the translation for "this" in "Vb.Net was "Me", but when I make
    the substitution, it does not translate correctly. What is the translation
    of this to VB.Net?
    Jim Heavey, Dec 2, 2003
    #1
    1. Advertising

  2. Jim Heavey wrote:
    > I found and example on the web where a event for a customValidator is
    > being loaded in code. It looks like the following..
    >
    > this.CustomValidator1.ServerValidate +=
    > new System.Web.UI.WebControls.ServerValidateEventHandler(
    > this.CustomValidator1_ServerValidate);


    You could just add 'Handles CustomValidator1.ServerValidate' to the
    signature of your event handling code.

    If you'd prefer to use AddHandler, this should do it (watch for word
    wrap):

    AddHandler CustomValidator1.ServerValidate, AddressOf
    CustomValidator1_ServerValidate

    --
    There are 10 kinds of people. Those who understand binary and those who
    don't.

    http://code.acadx.com
    (Pull the pin to reply)
    Frank Oquendo, Dec 2, 2003
    #2
    1. Advertising

  3. Jim Heavey

    Jim Heavey Guest

    Thanks!!!!!!!!!!!
    Jim Heavey, Dec 3, 2003
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Geni[X]MeN
    Replies:
    0
    Views:
    367
    Geni[X]MeN
    Jun 10, 2004
  2. Kieran Francisco

    Timing Diagram to HDL Translation

    Kieran Francisco, Sep 8, 2003, in forum: VHDL
    Replies:
    9
    Views:
    1,266
    VhdlCohen
    Sep 17, 2003
  3. Replies:
    0
    Views:
    2,692
  4. Simon Harvey

    Error message translation

    Simon Harvey, Feb 5, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    358
    Marina
    Feb 5, 2004
  5. tma

    Language translation

    tma, Jul 23, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    388
    Bryant Hankins
    Jul 23, 2004
Loading...

Share This Page