Got more questions? Find advice on: SQL | XML | Regular Expressions | Windows
in Search
Welcome to AspAdvice Sign in | Join | Help

fields in gridview can be edited depending on date

Last post 08-03-2007, 5:17 PM by ssmith. 1 replies.
Sort Posts: Previous Next
  •  08-02-2007, 10:02 AM 33505

    fields in gridview can be edited depending on date

    Hi,

     

    I am trying to create a web application which allows orders to be placed online. Certain items can only be ordered within a set period as they need to be produced once the order has been made.

     

    Is there anyway I can stop a field from being edited if it does not fall within a set date range distinguished within the database as well. Each 4 week period is set in table and with the help of a stored procedure the current period is always marked with a '1'. I hope this makes sense and someone can help. I am using VS 2005 and using C#.

     

    Thanks

     Sam

  •  08-03-2007, 5:17 PM 33550 in reply to 33505

    Re: fields in gridview can be edited depending on date

    You can change whether a row is editable, visible, formatted a certain way, or whatever you like by handling the OnItemDataBound() event of the Grid.  Within this event, you can test your data using whatever code you like.
    Steven A Smith
    President, AspAlliance LLC
    CIO, Lake Quincy Media, LLC
    Filed under:
View as RSS news feed in XML