I have embedded classic asp code into WSS using “page viewer” web part. Which is working fine. The problem is with the date format. In asp application I require the date to be in dd/mm/yyyy format. If
I run the asp code within WSS the date format is mm/dd/yyyy while if I run it on its own (outside WSS), the date appears as how I wanted.
FYI, I have only got WSS not SharePoint Portal. According to someone’s advice in one of the forum, I have even tried changing the date format under “regional settings” to “English (Australia)” but no use.
I am still getting an error saying:
Microsoft OLE DB Provider for SQL Servererror '80040e07'
The conversion of char data type to smalldatetime data type resulted in an out-of-range smalldatetime value.
Just because the date is not in dd/mm/yyyy format. Please help.
The server's date is in English UK, I have tried changing it to English Australia, but no use. I won't be dare to disturb the SQL server's collation format as there are important databases involved.
I have decided to change my asp code. I could have done this earlier if I just need to modify the code in 1 or 2 places but I will end up doing it at more then 200 places. I got no choice I guess. Please let me know if you got other alternative solutions.
Thanks
You are just amazing Brian. YES, it does work. <%@LCID=1037%>. GREAT. In fact, I have seen this segment of code in some of the asp files, but I never bothered to know
what is that all about. It always better to add that 1 line of code in every page rather than modifying every single code. Thanks Brian.
rrobet
Member
10 Points
48 Posts
Date format in WSS
Mar 15, 2007 11:09 AM|LINK
I have embedded classic asp code into WSS using “page viewer” web part. Which is working fine. The problem is with the date format. In asp application I require the date to be in dd/mm/yyyy format. If I run the asp code within WSS the date format is mm/dd/yyyy while if I run it on its own (outside WSS), the date appears as how I wanted.
FYI, I have only got WSS not SharePoint Portal. According to someone’s advice in one of the forum, I have even tried changing the date format under “regional settings” to “English (Australia)” but no use. I am still getting an error saying:
Microsoft OLE DB Provider for SQL Server error '80040e07'
The conversion of char data type to smalldatetime data type resulted in an out-of-range smalldatetime value.
Just because the date is not in dd/mm/yyyy format. Please help.
Brian@Planet
Member
96 Points
28 Posts
Re: Date format in WSS
Mar 15, 2007 03:50 PM|LINK
When you run the asp code as standalone vs within wss, is it accessing the same db server? Is it the same IIS box?
Are all components of the system set for English(Austrailia), not only WSS, but the hosting windows boxes and sql?
rrobet
Member
10 Points
48 Posts
Re: Date format in WSS
Mar 16, 2007 12:50 AM|LINK
The server's date is in English UK, I have tried changing it to English Australia, but no use. I won't be dare to disturb the SQL server's collation format as there are important databases involved.
I have decided to change my asp code. I could have done this earlier if I just need to modify the code in 1 or 2 places but I will end up doing it at more then 200 places. I got no choice I guess. Please let me know if you got other alternative solutions. Thanks
Brian@Planet
Member
96 Points
28 Posts
Re: Date format in WSS
Mar 16, 2007 04:49 PM|LINK
Well, I'm not sure it this will help but it's simple to try, you can specify the LCID per page <%@LCID=1037%> or <%@LANGUAGE="VBSCRIPT" LCID=1037%>
Otherwise I'm seeing similar reports and most of them are manually fixing the strings. Obviously change the LCID value to your region.
rrobet
Member
10 Points
48 Posts
Re: Date format in WSS
Mar 17, 2007 12:56 AM|LINK
You are just amazing Brian. YES, it does work. <%@LCID=1037%>. GREAT. In fact, I have seen this segment of code in some of the asp files, but I never bothered to know what is that all about. It always better to add that 1 line of code in every page rather than modifying every single code. Thanks Brian.
abhishek sax...
Member
2 Points
1 Post
Re: Date format in WSS
Mar 07, 2008 02:12 AM|LINK
Thanks a ton
this post saved my life [:D]