RE: Set readonly property on cell level in a datagridview



Hello Patrik,

As for the "DataGridView" control, do you mean the DataGrid or GridView
control? I'd like to confirm that you're using either of the two ASP.NET
template databound controls.

According to your description, you want to make a certain column(multiple
rows) in the GridView control have different editable status for each row
of that column, correct? If so, here are some of my understanding and some
questions which need your confirm:

** For the Readonly property of GridViews' columns, when you set it, it
will be applied to all the rows of that column, therefore, this property
can not be used to adjust individual cell(of a certain column)'s visibility
or edit mode.

** Since you want some rows of the column to be editable, how do you add
the edit UI/tempalte? Do you define two templates(ItemTemplate and
EditTemplate) or simply define only one template(ItemTemplate) and put
different control according to whether that row is editable?

** Is the "AddRows" event the "RowCreated" event of GridView? If so
what's your current code logic in it?

I would be helpful if you can provide us some code fragment to demonstrate
your current implement so that we can perform research on this.

Please feel free to post here if there is anything I missed.

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead



==================================================

Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications.



Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscriptions/support/default.aspx.

==================================================



This posting is provided "AS IS" with no warranties, and confers no rights.


.



Relevant Pages

  • Re: Web Form/SQL Table Structure
    ... So the Repeater tool output would look something like this: ... How would I call the correct control for the question (DropDownList, ... Microsoft MSDN Online Support Lead ... where an initial response from the community or a Microsoft Support ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: ContextMenuStrip and PreviewKeyDown
    ... Win32 control message model and input model. ... System.Windows.Forms.ContextMenuStrip class to "MyContextMenuStrip" class ... Microsoft Online Community Support ... where an initial response from the community or a Microsoft Support ...
    (microsoft.public.dotnet.languages.csharp)
  • RE: ObjectList Data-Binding to a List
    ... All I want is a control that allows me to manually build HTML ... Thanks for getting back to me about all these posts. ... Microsoft MSDN Online Support Lead ... where an initial response from the community or a Microsoft Support ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: trouble decoding managed call stack causing kernel complaint
    ... verbose symbol loading. ... you may use spy++ to find out that control. ... Microsoft Online Community Support ... where an initial response from the community or a Microsoft Support ...
    (microsoft.public.win32.programmer.kernel)
  • Re: DropDownList Input
    ... The control will then be added to the toolbox. ... "Nathan Sokalski" wrote: ... Microsoft MSDN Online Support Lead ... where an initial response from the community or a Microsoft Support ...
    (microsoft.public.dotnet.framework.aspnet.webcontrols)