This is a migrated thread and some comments may be shown as answers.

How to make a column disable false

5 Answers 43 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Anto (DLL Version : 2008.3.1314.35)
Top achievements
Rank 2
Anto (DLL Version : 2008.3.1314.35) asked on 24 Oct 2009, 01:48 PM
Hi All

I have a radgrid with some records. Its working fine.

I need to make a column disable false when I load the page.

Is there any option for this.

Thank You

-Anto

5 Answers, 1 is accepted

Sort by
0
Daniel
Telerik team
answered on 25 Oct 2009, 07:59 PM
Hello Anto,

I'm not sure that I understand your question completely. Could you please provide more details?

Regards,
Daniel
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Anto (DLL Version : 2008.3.1314.35)
Top achievements
Rank 2
answered on 26 Oct 2009, 07:28 AM
Hi Daniel

I have a radgrid with (EmpCode, EmpName, Address, Date Of Birth, Date Of Joining)

Let it be there ae some 25 records.

What I need is: The Column Date Of Joining should be disabled.(Enable="false")

Is there any option for it.

-Anto
0
Daniel
Telerik team
answered on 26 Oct 2009, 09:58 AM
Hello Anto,

I suppose you want to disable the column in edit mode. If so, you can use the ReadOnly property as shown below:
<telerik:GridBoundColumn ReadOnly="true" ...>
   ...
</telerik:GridBoundColumn>

Let me know if I'm missing something

Regards,
Daniel
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Anto (DLL Version : 2008.3.1314.35)
Top achievements
Rank 2
answered on 26 Oct 2009, 10:17 AM
Hi Daniel

You are correct.

But my requirement is: Need to disable the column Date Of Joining.

When the radgrid is viewed the column Date Of Joining should be disabled.

Reason:

I have taken the value in the cell when the RowDoubleClick, so need to diasble it.

-Anto
0
Princy
Top achievements
Rank 1
answered on 27 Oct 2009, 07:16 AM
Hello Anto,

To have the column disabled in a grid, in normal mode, you can disable it as shown below:
c#:
protected void RadGrid_ItemCreated(object sender, Telerik.Web.UI.GridItemEventArgs e) 
    { 
        if (e.Item is GridDataItem) 
        { 
            GridDataItem dataItem = (GridDataItem)e.Item; 
            dataItem["DateOfJoiningColumnUniqueName"].Enabled = false
 
        }  
    } 

Thanks
Princy.
Tags
Grid
Asked by
Anto (DLL Version : 2008.3.1314.35)
Top achievements
Rank 2
Answers by
Daniel
Telerik team
Anto (DLL Version : 2008.3.1314.35)
Top achievements
Rank 2
Princy
Top achievements
Rank 1
Share this question
or