Click here to Skip to main content
15,890,377 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
How can I expand the datagridview column as the user is typing.
Posted

Hi,
you might try subscribing to CellBeginEdit event, and expand it dynamically. It kind of an ugly solution, but I do not see other way of doing it.
Regards
 
Share this answer
 
Catch the appropriate event on the cell, measure the current text, resize the column by assigning to its Width property.

For the first part (which is harder than it should be), see here[^] or other things Google will find you.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900