Friday, 21 November 2008
Login
|
Register
Home
Web Application Development
Products
About Us
Contact Us
Forum
Blog
Important
To be able to post to this forum you must be a registered user. To register click the 'Register' link at the top right of this page, below the search box.
Unregistered users may view the forums.
Forum
Search
Forum Home
DatePicker
Installation / Setup
The class does ...
The class does not contain a definition for 'DatePicker1'
28/03/2007 12:54:55 PM
dli7mar
6 posts
The class does not contain a definition for 'DatePicker1'
Hi,
In my asp.net 2.0 web application, I added the DatePicker control to the toolbox and dragged it to a web form. But when I need to get its value in the btnSubmit_Click(), I got an error message:
'namespace1.form1' does not contain a definition for 'DatePicker1'.
I tried to add a line at the begining: using EclipseWebSolutions.DatePicker;
but it does not help. Did I miss something here?
Thanks in advance,
-dli7mar
30/03/2007 6:30:11 PM
admin
35 posts
Re: The class does not contain a definition for 'DatePicker1'
I have not seen that before. Please post or email me your code and/or the full error message. I suggest that you also look at the demo application.
Regards,
Liam McLennan
liam@eclipsewebsolutions.com.au
31/03/2007 4:18:19 AM
dli7mar
6 posts
Re: The class does not contain a definition for 'DatePicker1'
Here is what I did. I created a bin folder under foo/foo (suppose my asp.net 2.0 application name is foo), and copy the assembly EclipseWebSolutions.DatePicker.dll to foo/foo/bin/. Then added the DatePicker Control to the Visual Studio toolbox, and then dragged it to a web form.
I guess the first time when I dragged the DatePicker to the form, I got a message to say 'Web.config has been modified outside of the source editor, do you want to reload?'. I clicked the wrong button to reload it so that I lost the changes to Web.config file.
If I manually add the following line to Web.config (same as in your demo) :
then I got a long list of errors, the first one is:
'Could not find schema information for the element 'http://schemas.microsoft.com/.NetConfiguration/v2.0:configuratopn'.
I found Version=1.0.61025.0 does not match the version of EclipseWebSolutions.DatePicker.dll (2.1.2581.35733), I tried 2.1.2581.35733, but it's still same thing.
I guess since I lost the changes in Web.config, that’s the reason I got message:
'namespace1.class1' does not contain a definition for 'DatePicker1'.
How do I add this assembly to Web.config?
Many Thanks,
-dli7mar
31/03/2007 9:02:59 AM
admin
35 posts
Re: The class does not contain a definition for 'DatePicker1'
You should not need to add anything to the web.config to support the datepicker. Just add it to the toolbox and drag it onto your form. I think the problems may not be related to the DatePicker. Have you tried creating a clean project and trying to get it to work?
Regards,
Liam McLennan.
2/04/2007 8:37:10 AM
dli7mar
6 posts
Re: The class does not contain a definition for 'DatePicker1'
You’re right. The problem is not related to the Date Picker. I created a new form and only put a Date Picker, a label, and a button onto it and then it worked perfect. But When I added the master page to this form, then the calendar did not move to the previous or next month when I clicked < or > (it would be closes). Do you have any idea about this issue?
Many Thanks,
-dli7mar
Here is my simple form with the master page:
<%@ Page Language="C#" MasterPageFile="~/MasterDaqi.Master" AutoEventWireup="true" CodeBehind="Test2Frm.aspx.cs" Inherits="Appeals.Test2Frm" Theme="myThemes" %>
<%@ Register Assembly="EclipseWebSolutions.DatePicker" Namespace="EclipseWebSolutions.DatePicker"
TagPrefix="cc1" %>
2/04/2007 5:51:31 PM
admin
35 posts
Re: The class does not contain a definition for 'DatePicker1'
Try this example of using the datepicker with a masterpage. I don't know if it will help. I was not able to reproduce your issue.
DatepickerWMasterpage.zip
3/04/2007 5:08:44 AM
dli7mar
6 posts
Re: The class does not contain a definition for 'DatePicker1'
Based on your example, I added all my items to the master page one by one, and it worked perfect. I think a tag that was not organized well caused the problem. Thanks a lot for your help.
One more question to you: When I try to run your demo, I unzipped the files to C:\ews_datepicker. Then open web site C:\ews_datepicker through VS 2005, then highlight Default.aspx, and click the Start button to run it. But I got a message:
Unable to update auto-refresh reference 'eclipsewebsolutions.datepicker.dll'. Cannot find assembly 'C:\code\DatePicker_Source\bin\Debug\EclipsWebSolutions.DatePicker.dll'.
Did I do something wrong here? Any idea about this one?
Many Thanks,
-dli7mar
3/04/2007 5:25:23 AM
admin
35 posts
Re: The class does not contain a definition for 'DatePicker1'
That message should be a warning not an error. On my computer if the
EclipsWebSolutions.DatePicker.dll file is changed the test project that I sent you will automatically copy it. Obviously when you run it C
:\code\DatePicker_Source\bin\Debug\EclipsWebSolutions.DatePicker.dll is not there so it can't automatically update the dll. If you look in the bin directory you should see a file called E
clipsWebSolutions.DatePicker.dll.refresh. This is the file that contains the incorrect path. If you delete it I think the message will go away. Glad it is working for you.
Regards,
Liam McLennan.
4/04/2007 6:53:39 AM
dli7mar
6 posts
Re: The class does not contain a definition for 'DatePicker1'
I think I need to install asp.net AJAX to run your demo.
Thank you very much for all your helps,
-dli7mar
4/04/2007 7:18:32 AM
admin
35 posts
Re: The class does not contain a definition for 'DatePicker1'
The master pages demo I sent yesterday does not use AJAX.
Regards,
Liam.
Page 1 of 1
DatePicker
Installation / Setup
The class does ...
Flat View
Tree View
Oldest To Newest
Newest To Oldest
Copyright 2007 by Eclipse Web Solutions Pty Ltd
|
Privacy Statement
|
Terms Of Use