I am a new user of UltraGrid and I find all the configuration option a little overwhelming.
I would like to create a read only grid. I would like the user to be able to select only a single cell at any time, and I would like to display a pop up menu to allow the user to copy the contents of the selected cell to the clipboard on right click.
Any help would be appreciated. TIA!
D'oh! A piece of code I copied and pasted into the grid ClickCell event handler to implement the context menu was selecting the row. Everything works great now. Thanks again, Alan.
private void ultraGrid1_InitializeLayout(object sender, Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs e) { var layout = e.Layout; var ov = layout.Override; ov.ActiveCellAppearance.Reset(); ov.ActiveRowAppearance.Reset(); }
Thanks, Mike. How do I turn off the default ActiveCellAppearance and ActiveRowAppearance in code?
You might want to turn off the default ActiveCellAppearance and ActiveRowAppearance, anyway. Just to avoid confusion:
devcenter.infragistics.com/.../KnowledgeBaseArticle.Aspx
Nicholas,
If it was just the appearance of the grid, I would think that you might be looking at the activation of the row which would still happen when selecting only a single cell. As the values for the entire row are being pasted, I would assume that somehow the entire row is being selected in your grid though with the code provided I wouldn't expect that to happen. Are you able to reproduce the behavior with the same code in an isolated sample that you could provide for me to debug to see what is happening. I did test the individual settings when I first responded though I didn't get the behavior you are describing.