469,578 Members | 1,718 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,578 developers. It's quick & easy.

Retrieve web form name or id?

Hi guys,

is it possible to retrieve the name or the id of a form in an ASP.Net page?
In the code behind inside the page class, I would like to be able to
reference to that "form object" and to retrieve its name or id. is that at
all possible?

Cheers

Jul 21 '05 #1
4 1361
Edward,

me.name (VBNet)
this.name (C#)

I hope this helps?

Cor
"Edward Lim" <ed************@iinet.net.au>
Hi guys,

is it possible to retrieve the name or the id of a form in an ASP.Net
page?
In the code behind inside the page class, I would like to be able to
reference to that "form object" and to retrieve its name or id. is that at
all possible?

Cheers


Jul 21 '05 #2
JD
Probably something like:

MyPage.Form.UniqueId
Or
MyPage.Form.Name
"Edward Lim" <ed************@iinet.net.au> wrote in message
news:41**********************@per-qv1-newsreader-01.iinet.net.au...
Hi guys,

is it possible to retrieve the name or the id of a form in an ASP.Net page? In the code behind inside the page class, I would like to be able to
reference to that "form object" and to retrieve its name or id. is that at
all possible?

Cheers


Jul 21 '05 #3
JD
Oops forget the MyPage, just "Form.UniqueId" or "Form.Name".
"JD" <no@spam.com> wrote in message news:nLwjd.379639$D%.343549@attbi_s51...
Probably something like:

MyPage.Form.UniqueId
Or
MyPage.Form.Name
"Edward Lim" <ed************@iinet.net.au> wrote in message
news:41**********************@per-qv1-newsreader-01.iinet.net.au...
Hi guys,

is it possible to retrieve the name or the id of a form in an ASP.Net

page?
In the code behind inside the page class, I would like to be able to
reference to that "form object" and to retrieve its name or id. is that at all possible?

Cheers



Jul 21 '05 #4
Hi JD,

I can't seem to find the methods "UniqueId" or "Name" in the form class, and
I presume you actually meant

Request.Form.UniqueId and Request.Form.Name right?

Unless we are talking different version of Dot Net Framework. I am using 1.1
only.

Thanks and Regards,
Edward

"JD" <no@spam.com> wrote in message news:COwjd.70525$R05.10690@attbi_s53...
Oops forget the MyPage, just "Form.UniqueId" or "Form.Name".
"JD" <no@spam.com> wrote in message
news:nLwjd.379639$D%.343549@attbi_s51...
Probably something like:

MyPage.Form.UniqueId
Or
MyPage.Form.Name
"Edward Lim" <ed************@iinet.net.au> wrote in message
news:41**********************@per-qv1-newsreader-01.iinet.net.au...
> Hi guys,
>
> is it possible to retrieve the name or the id of a form in an ASP.Net

page?
> In the code behind inside the page class, I would like to be able to
> reference to that "form object" and to retrieve its name or id. is that at > all possible?
>
> Cheers
>
>
>
>
>



Jul 21 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

5 posts views Thread by Edward Lim | last post: by
reply views Thread by suresh191 | last post: by
4 posts views Thread by guiromero | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.