HighTechTalks DotNet Forums  

Several issues with building a user control

ASP.net Building Controls microsoft.public.dotnet.framework.aspnet.buildingcontrols


Discuss Several issues with building a user control in the ASP.net Building Controls forum.



Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old   
AT
 
Posts: n/a

Default Several issues with building a user control - 06-30-2003 , 03:39 PM






Hello all,

I'm trying to build a user control (specifically, a date picker) and
am experiencing several issues. Also, I'm brand new to web development
and ASP.Net, so hopefully this will be fairly basic.

First, when I place the control on a WebForm, the designer lets me
place it exactly where I want it. However, when I run the app, the
control is displayed in the top left corner of the parent container
regardless of where it was in the designer.

Second, when the control is loaded, I run a method to fill the month,
day, and year DropDownLists with their values. However, they are empty
when they are displayed. I know the code is executed, because I can
throw an exception in the method. The AutoPostBack is set to true but
I don't think this is ever triggered. One way I can think of is to
force a PostBack but it doesn't seem that I'd need to.

Thirdly, if I have the control in a separate .dll that is referenced
by the web app, and include the namespace that it is under, I get the
following exception when attempting to run the app, even though I've
only got it defined in one .dll that is referenced: "CS1595:
'CustomWebControls.DateTimePicker' is defined in multiple places;
using definition from...". This is a problem because I want to be able
to access the object in C# code.

Lastly, how do you add a user control to the toolbox? When I select
customize toolbox, and find the .dll that the control is in, I'm told
that there are no items in the .dll that can be added to the toolbox.

Thanks in advance,
Shannon

Reply With Quote
  #2  
Old   
AT
 
Posts: n/a

Default Re: Several issues with building a user control - 07-05-2003 , 05:57 AM






Why waste your precious time on develope it yourself?
Take a look at http://www.orilogic.com/products

Easy to use Date Picker, only cost $5.90,

Rgds

scayze (AT) us (DOT) loreal.com (Shannon Cayze) wrote in message news:<f9c7c737.0306301139.66bae968 (AT) posting (DOT) google.com>...
Quote:
Hello all,

I'm trying to build a user control (specifically, a date picker) and
am experiencing several issues. Also, I'm brand new to web development
and ASP.Net, so hopefully this will be fairly basic.

First, when I place the control on a WebForm, the designer lets me
place it exactly where I want it. However, when I run the app, the
control is displayed in the top left corner of the parent container
regardless of where it was in the designer.

Second, when the control is loaded, I run a method to fill the month,
day, and year DropDownLists with their values. However, they are empty
when they are displayed. I know the code is executed, because I can
throw an exception in the method. The AutoPostBack is set to true but
I don't think this is ever triggered. One way I can think of is to
force a PostBack but it doesn't seem that I'd need to.

Thirdly, if I have the control in a separate .dll that is referenced
by the web app, and include the namespace that it is under, I get the
following exception when attempting to run the app, even though I've
only got it defined in one .dll that is referenced: "CS1595:
'CustomWebControls.DateTimePicker' is defined in multiple places;
using definition from...". This is a problem because I want to be able
to access the object in C# code.

Lastly, how do you add a user control to the toolbox? When I select
customize toolbox, and find the .dll that the control is in, I'm told
that there are no items in the .dll that can be added to the toolbox.

Thanks in advance,
Shannon

Reply With Quote
Reply




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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.