bool inPaste = false;
private void gridControl1_ClipboardPaste(object sender, GridCutPasteEventArgs e)
{
if (inPaste)
return;
inPaste = true;
gridControl1.Model.IgnoreReadOnly = true;
gridControl1.Model.CutPaste.Paste();
e.Handled = true;
gridControl1.Model.IgnoreReadOnly = false;
inPaste = false;
}
Stefan
>Hi,
>my first 2 columns of the DataBoundGrid are readonly.
>when i insert new rows and try to copy using the
>below command it says can not set the column value
>this.m_ListingGrid.Model.CutPaste.Paste();
>
>i have set the IgnoreReadOnly property but this works just once next time again it throws the same error.
>m_ListingGrid.Model.IgnoreReadOnly = true;
>
>Is there any other way that i can make those cells writable during insert paste and other time just readonly
>
>
>
>
>
>bool inPaste = false;
>
>private void gridControl1_ClipboardPaste(object sender, GridCutPasteEventArgs e)
>{
> if (inPaste)
> return;
>
> inPaste = true;
> gridControl1.Model.IgnoreReadOnly = true;
> gridControl1.Model.CutPaste.Paste();
>e.Handled = true;
> gridControl1.Model.IgnoreReadOnly = false;
> inPaste = false;
>}
>
>
>Stefan
>
>
>>Hi,
>>my first 2 columns of the DataBoundGrid are readonly.
>>when i insert new rows and try to copy using the
>>below command it says can not set the column value
>>this.m_ListingGrid.Model.CutPaste.Paste();
>>
>>i have set the IgnoreReadOnly property but this works just once next time again it throws the same error.
>>m_ListingGrid.Model.IgnoreReadOnly = true;
>>
>>Is there any other way that i can make those cells writable during insert paste and other time just readonly
>>
>>
>>