Mitchel's Forums

Subject: Web user controls - enforce parameter passing
Prev Next
You are not authorized to post a reply.

AuthorMessages
shira abramUser is Offline
New Poster
New Poster
Posts:10

09/10/2008 10:31 AM  

Hi,

I was wondering it there is a way to force parameter passing to a user control, something like a constructor.
The only way I know of to pass parameters is through Properties, but that does not guarantee that all the parameters will indeed be passed. A future client of the control may not even know which parameters he should pass. 

Mitchel SellersUser is Offline
Site Admin/Owner
Guru
Guru
Posts:5595

09/11/2008 5:07 PM  
There really isn't any way that I know, as the declarative manner of user control creation is not really supporting of that type of architecture.

My best recommendation on this would be to define well structured errors that your module/control can pass on the event of a missing parameter

-Mitchel Sellers
MCITP, MCPD, MCTS
Director of Development
IowaComputerGurus Inc.

View Mitchel Sellers's profile on LinkedIn

3Essentials is my recommended Shared Hosting Provider

This site is hosted on a VPS from HostMySIte.com

Mosso is my recommended cloud computing provider. Use reference code REF-ICG to get $100 off your second month!

To get Guaranteed DNN Support check out our affordable DNN Technical Support Programs
You are not authorized to post a reply.
Forums >Development Discussion >.NET Development > Web user controls - enforce parameter passing



ActiveForums 3.7