Solved

C#: add a non-editable field telerik

Posted on 2015-01-19
3
89 Views
Last Modified: 2015-01-28
i want to add a non-editable field box in a telerik form. I have the following.

 <telerik:GridBoundColumn DataField="code" EditFormColumnIndex="0" HeaderText="Code" />
 
 however, this displays an editable box. if i do readOnly. it disappears all together
 
  <telerik:GridBoundColumn DataField="code" EditFormColumnIndex="0" HeaderText="Code" ReadOnly="true" />
0
Comment
Question by:badtz7229
  • 2
3 Comments
 
LVL 16

Expert Comment

by:Easwaran Paramasivam
ID: 40559774
Remove  EditFormColumnIndex="0"
0
 

Accepted Solution

by:
badtz7229 earned 0 total points
ID: 40559874
@Easwaran Paramasivam : that didn't work. it still is editable.

i did find a solution:
in my _ItemDataBound function
            GridEditFormItem editFormItem = (GridEditFormItem)e.Item;
            TextBox TextBox1 = (TextBox)editFormItem["code"].Controls[0];
            TextBox1.Enabled = false;
0
 

Author Closing Comment

by:badtz7229
ID: 40574833
it resolved issue for me.
0

Featured Post

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
Calculating holidays and working days is a function that is often needed yet it is not one found within the Framework. This article presents one approach to building a working-day calculator for use in .NET.
Along with being a a promotional video for my three-day Annielytics Dashboard Seminor, this Micro Tutorial is an intro to Google Analytics API data.
Migrating to Microsoft Office 365 is becoming increasingly popular for organizations both large and small. If you have made the leap to Microsoft’s cloud platform, you know that you will need to create a corporate email signature for your Office 365…

911 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now