Chatur
Chatur

Reputation: 431

How to put icon in a datagrid view in C# .net 4.0 windows forms application?

I need to have icons in a column of a datagridview in C# .net 4.0 windows form application.

Upvotes: 0

Views: 956

Answers (2)

Oliver
Oliver

Reputation: 45101

After reading the answer from @leppie and your comments i would suggest the following:

Create a UserControl that shows the image and some text. Take care that it will look good, regardless the size of the control (since some MinimumSize) by using Anchoring, Docking, FlowLayoutPanel, whatever.

After successfully creating your own control that is capable of holding some text AND a image, take this tutorial from Microsoft and put your UserControl into it as DataGridViewUserControlColumn.

Upvotes: 1

leppie
leppie

Reputation: 117250

Probably the same as .NET 3.5.

Just use an Image column.

Upvotes: 0

Related Questions