Tell me more ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

DateTimeControl is inside grid and i bind grid inside !ispostback section, on row databound of grid i find that datetimecontrol and disabled it.

when button click(outside of grid) DateTimeControl gets enable.

No code inside button click event.

How to resolve???

share|improve this question
And you haven't written any code on Button_Click event? – Arsalan Adam Khatri Dec 18 '12 at 5:45
no i hadn't written any code on Button_Click. – Hitesh Chandegara Dec 18 '12 at 5:46
DateTimeControl is inside grid and i bind grid inside !ispostback section, on row databound of grid i find that datetimecontrol and disabled it. – Hitesh Chandegara Dec 18 '12 at 5:53
I think it would be easier if you just show us your problematic code. – Mike Dec 28 '12 at 15:05

3 Answers

Please be more specific to what you want to achieve. Instead of you binding dateTime control at !ispostback section why don't you try adding a date and time column to SharePoint list.

If you are using the data from external sources such as sql then you should consider using external list in BDC which is for same purpose i.e. binding a Sharepoint list from external datasource .

share|improve this answer

please try adding below code in databound event

DateTimeControl dtc = new DateTimeControl();

((TextBox)dtc.Controls[0]).ReadOnly = true;

please let me know if this works for you.

regards manish

share|improve this answer

I don't think this is possible.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.