Design Time Support

  • Thread starter Thread starter Cor Ligthert
  • Start date Start date
C

Cor Ligthert

Hi Zviki,

I am not sure what you are after however I get somehow the idea that you
need something as this?

Cor
\\\
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
Dim frm As Control = Me.FindControl("Form1")
Dim ctl As Control
For Each ctl In frm.Controls
Dim tb As TextBox
If TypeOf ctl Is TextBox Then
tb = DirectCast(ctl, TextBox)
tb.Text = String.Empty
End If
Next
///
 
Hi..

I need to know in design time in ASP.NET inside a control (for ex), who is
the Page that contain him. I tried to use the Pae property or the Parent
property but they are NULL.
I need tha page type or namr or something like that.

Is it possible ??

Thanks a lot

Zviki.
 
Thanks for your answer, but it does not help.
I have a control that can be placed on many forms and I need from inseide to
know who is the parent page. I tried what you suggested and it return NULL,
even if I know that name of the parent page.

Do you have any other suggestion ?

Thanks

Zviki
 
Hi Zviki,

This did give back to me Form1 the Id of the parent.

Dim a As String = Me.Image1.Parent.UniqueID

I hope this helps?

Cor
 
Back
Top