We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

How do I change the current selection?

I want to be able to restrict the user to selecting multiple cells in one column only (i.e. to only be able to make vertical selections of one or more cells). How do I go about doing this? All the objects and properties that appear to be the obvious thing to modify (like MyGrid.Selections.Ranges.ActiveRange) are read-only.

1 Reply

MS Maxim Software Systems May 9, 2003 01:09 PM UTC

Nevermind. Putting this line of code: If e.Range.Left <> e.Range.Right Then e.Cancel = True into the SelectionChanging event seems to do the trick.

Live Chat Icon For mobile
Up arrow icon