Geeks With Blogs
Gaurav Taneja Great dreams... never even get out of the box. It takes an uncommon amount of guts to put your dreams on the line, to hold them up and say, "How good or how bad am I?" That's where courage comes in.

 

How to fetch Page controls of web form Dynamically in vb.net

 

To Find the Page Controls in a Web Page
 
Public Function FindPageControl(ByVal oControlCollection As ControlCollection, ByVal strPageName As String) As ArrayList
        ' Traverses all the controls in the page
        For Each oControl As Control In oControlCollection
            DisplayControlName(oControl, strPageName)
            FindPageControl(oControl.Controls, strPageName)
        Next
        Return ArrayLst
    End Function
How to call this function
 
FindPageControl(Page.Controls, strPgName)
Posted on Wednesday, December 10, 2008 10:49 PM | Back to top


Comments on this post: Fecting Page controls Dynamically + vb.net

No comments posted yet.
Your comment:
 (will show your gravatar)


Copyright © Gaurav Taneja | Powered by: GeeksWithBlogs.net