Auteur de questions
To be precise February dates(30,31 or 29 in case not a leap year)
Toutes les réponses
I have a Business Data List WebPart which shows 90 days old data based on current data.
everything is setup correctly, Except two major problems:
1) User is able to enter date as 02/30/2011 or 02/31/2011 (mm/dd/yyyy format)
which is logically wrong. I also wish to consider a case of leap year (February month)
2) Also every early year(ie. Jan or Feb Month) the data appears incorrect as it shows 90 days old data based on current date.
Hope this information is enough to understand the issue.
I can only suggest taking a look at ViewSource of the rendered Page with your web-part and find what Html-elements are parts of the Business Field you want to validate. Find input-tag which contains the date inserted by user and div-tag which is used to display date. You need to get their id(s). Add to the web-part code to add startup client script to the page. This code will hook up on textchanged-event (or blur-event) of the input-tag. An event handler will validate the current value and show message if date isn't correct. Also you probably need to add some client code before the form sent data to the server, I remember (if I'm not wrong at all) only that this can be achieved by built-in means of ASP.NET.
.Net Follower (http://dotnetfollower.com)