G
Guest
Hi,
I am attempting to troubleshoot the following error, so far with no success.
[InvalidCastException: Cast from string "06/17/2004" to type 'Date' is not valid.]
Microsoft.VisualBasic.CompilerServices.DateType.FromString(String Value, CultureInfo culture) +163
Microsoft.VisualBasic.CompilerServices.DateType.FromString(String Value) +53
cp_ContactManagement_v2_0.CallReport.Page_Load(Object sender, EventArgs e) in c:\inetpub\wwwroot\cp_ContactManagement_v2_0\CallReport.aspx.vb:243
System.Web.UI.Control.OnLoad(EventArgs e) +67
System.Web.UI.Control.LoadRecursive() +35
System.Web.UI.Page.ProcessRequestMain() +731
It is being generated from within a web application - here is the line that fails:
dtbOpenDate.xDate = Now.ToString("MM/dd/yyyy")
The error is generated only when the dll is run from my local host - many other machines including the server that hosts the site run it successfully. I have checked the date settings in my regional settings to no avail. If I change the formatting to "dd/MM/yyyy" it executes successfully, but then other failures occur. I have reinstalled my development environment environment but still have the problem.
I have not yet reinstalled IIS which is what I guess I will try next.
Thanks for any ideas you may have,
I am attempting to troubleshoot the following error, so far with no success.
[InvalidCastException: Cast from string "06/17/2004" to type 'Date' is not valid.]
Microsoft.VisualBasic.CompilerServices.DateType.FromString(String Value, CultureInfo culture) +163
Microsoft.VisualBasic.CompilerServices.DateType.FromString(String Value) +53
cp_ContactManagement_v2_0.CallReport.Page_Load(Object sender, EventArgs e) in c:\inetpub\wwwroot\cp_ContactManagement_v2_0\CallReport.aspx.vb:243
System.Web.UI.Control.OnLoad(EventArgs e) +67
System.Web.UI.Control.LoadRecursive() +35
System.Web.UI.Page.ProcessRequestMain() +731
It is being generated from within a web application - here is the line that fails:
dtbOpenDate.xDate = Now.ToString("MM/dd/yyyy")
The error is generated only when the dll is run from my local host - many other machines including the server that hosts the site run it successfully. I have checked the date settings in my regional settings to no avail. If I change the formatting to "dd/MM/yyyy" it executes successfully, but then other failures occur. I have reinstalled my development environment environment but still have the problem.
I have not yet reinstalled IIS which is what I guess I will try next.
Thanks for any ideas you may have,