Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7398995
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T03:56:58+00:00 2026-05-29T03:56:58+00:00

Im using a telerik gridview for silverlight and Im trying to programatically set the

  • 0

Im using a telerik gridview for silverlight and Im trying to programatically set the maximum character length on each individual column after the gridview is populated with data.
I want to make it so when the user is inserting or editing a column’s cell, the maximum (char) length is set based on a control records max length. So far Ive only been able to set the MaxWidth, but that doesnt help me because the column header is always longer than the atual text allowed, and the MaxWidth sets the column width in pixels, not the columns editing max character length. Can someone point me in the right direction. I can provide some code if need be.

Ive tried setting it to
column.CellEditTemplate.SetValue(TextBoxEditor.MaxLengthProperty, MYMAXLENGTH);

but it gives me an error.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T03:56:59+00:00Added an answer on May 29, 2026 at 3:56 am

    How about something like this?

    Style textBoxStyle = new Style(typeof(TextBox));
    textBoxStyle.Setters.Add(new Setter(TextBox.MaxLengthProperty, myMaxLength));
    (this.MyGrid.Columns[0] as GridViewBoundColumnBase).EditorStyle = textBoxStyle;
    

    http://www.telerik.com/community/forums/silverlight/gridview/best-way-to-set-maxlength-on-gridviewdatacolumn.aspx

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am using a Telerik GridView , and having an issue trying to sort
I am new to jQuery, trying to populate a GridView or Telerik RadGrid using
Currently i am using Telerik grid which filters are applied to each column. I
I am using Telerik Silverlight RadGridView to display instrument prices. There is a column
I'm using the new Telerik Rad Control and I would to use the GridView
Currently using Telerik ASP .NET MVC Controls version 2011.2.712 Hello all, I am trying
We are using Telerik radcontrols in our web form and I am trying to
I am using teleriks gridview in an mvvm silverlight project. I am struggling to
I am using Telerik's RadGridView to display some data. When data in one column
Using telerik mvc grid with ajax, give me some headaches. I am trying to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.