Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
ASP.NET 1.0 and 1.1 Professional For advanced ASP.NET 1.x coders. Beginning-level questions will be redirected to other forums. NOT for "classic" ASP 3 or the newer ASP.NET 2.0 and 3.5
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.0 and 1.1 Professional section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old November 20th, 2006, 12:56 PM
Wrox Author
Points: 13,255, Level: 49
Points: 13,255, Level: 49 Points: 13,255, Level: 49 Points: 13,255, Level: 49
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
Join Date: Oct 2005
Location: Ohio, USA
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default Design Question/Problem

Ok, this is an interesting problem.

I have a dll that I created that provides specialized functionality for a certain part of my app and, originally, I had just created the necessary UI elements as part of the page and wired the controls up to the DLL to pass in and return values.

Well in an attempt to be more effecient, I rewrote my dll to also handle the UI portion as well.

First, I have thought about usercontrols but this is not going to solve my problem because, depending on where this functionality is exposed on my app, the UI is extremely different BUT the functionality in the DLL does not change.

So here is what I have done: in my dll i create an HTML table and create all of the elements dynamically (text box, button, dropdownlist) and add those to my table. This table then gets returned to the requesting page for display.

What I am tackling, is the click event of the button. Because it is generated in the dll I cant, at control creation, do:

btn.click += new System.EventHandler(this.btnClick);

Because btnClick does not exist in the dll, it would exist on the container page. What I could do is loop through the table that is returned from the dll and find the button control and add the hanlder that way but I didn't know if anyone on the boards had a better idea.

Any ideas?

I will only tell you how to do it, not do it for you.
Unless, of course, you want to hire me to do work for you.

^^Thats my signature
Doug Parsons
Wrox online library: Wrox Books 24 x 7
Did someone here help you? Click on their post!
"Easy is the path to wisdom for those not blinded by themselves."

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
design question androoo ADO.NET 1 November 13th, 2004 09:41 AM
design question androoo .NET Web Services 1 November 13th, 2004 09:39 AM
Design Question flyin General .NET 4 July 21st, 2004 03:59 PM
Design question? qadeer05 SQL Server 2000 4 May 3rd, 2004 10:17 AM

All times are GMT -4. The time now is 10:28 PM.

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.