Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Building Controls > Using the same User Control multiple times on one page

Reply
Thread Tools

Using the same User Control multiple times on one page

 
 
Raith
Guest
Posts: n/a
 
      07-06-2005
How can I reuse a User Control multiple times on a single page?
I have one created that pulls and hyperlinks the most recent news items from the database.
I want to reuse it multiple times, one instance in each javascript dropdown menu on the page.
I plan to pass the catagoryID via each individual menu node, but my problem is in trying to register and reuse this control.
One always shows up alright and the other has nothing. I have tried registering twice above, using different prefixes, using different tags, etc.
Is it possible to reuse a control like this several times on the same page?

Thanks.

From http://www.developmentnow.com/g/10_0...ngcontrols.htm

Posted via DevelopmentNow.com Groups
http://www.developmentnow.com
 
Reply With Quote
 
 
 
 
smyersm@gmail.com
Guest
Posts: n/a
 
      07-07-2005
I create controls and reuse them an unlimited number of times in a
page.

Dim X as new coolControl()
Dim Y as new coolControl()

Controls.Add(X)
Controls.Add(Y)

I dont know the specifics from YOUR control, but i have over 50
controls, some extended from others, some brand new. Good luck

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
str.Template 4 times slower than calling replace multiple times Jack Steven Python 2 03-09-2009 05:38 AM
What is the best practice to have a user control placed multiple times on a page? Gummy ASP .Net 9 09-19-2006 03:32 PM
Display same image on a page multiple times yk Javascript 6 09-13-2006 02:14 PM
UserControl loaded dynamically multiple times on same page....client js problem ibejo@ibejo.com ASP .Net Web Controls 1 07-18-2006 07:30 AM
how to use same user control x number of times on same asp page David Hubbard ASP .Net 2 01-12-2006 03:56 PM



Advertisments