Questions tagged [datagridviewimagecolumn]

42 questions
2
votes
1 answer

Add image to DataGridView using DataGridViewImageColumn

I am trying to add an image in a DataGridView using the following code DataGridViewImageColumn Editlink = new DataGridViewImageColumn(); Image image = Image.FromFile("Images\\Edit.png"); Editlink.Image = image; Editlink.HeaderText =…
Parag Pathari
  • 281
  • 2
  • 5
  • 19
2
votes
1 answer

DataGridView image column issue on sorting

I have a DataGridView that has an image column. The image address is read from one of the cells of the same row and then shown. When I sort the columns the images go away. I'm using Visual Studio 2010 and coding in C#. Data is retrieved from…
Afshin K
  • 21
  • 4
2
votes
1 answer

Change the type of a DataGridViewColumn using AutoGenerateColumns

I have a query using a dynamic pivot table which will return me a different number of columns to bind to my DataGridView. I am using AutoGenerateColumns = true...which is the only way to display the pivot columns. How can I programmatically make…
1
vote
2 answers

How to change or remove the null image in a DataGridViewImageColumn including the new Row

How to remove null image in datagridview column image in vb.net? Is there a way to remove null image in datagridview column image? Private Sub TextBox1_KeyPress(sender As Object, e As KeyPressEventArgs) Handles TextBox1.KeyPress If e.KeyChar =…
1
vote
1 answer

Cell selection hides behind image DataGridViewImageCell

I'm using Winform DataGridView to display images. But when image fills cell, I don't see blue selection or in very low quantity. Please see: When an cell is selected, I expect make cell whole transparent blue, not just sides or sides which isn't…
Gray Programmerz
  • 479
  • 1
  • 5
  • 22
1
vote
1 answer

Is it possible to hide the header cell in a DataGridView for specific columns?

I have a DataGridView which is populated from a DataTable. I then supplement this with additional DataGridViewImageColumn which will ultimately function as buttons for manipulating the data on any given row. What I want to know is, is it possible to…
1
vote
1 answer

Image not displaying in datagridview column in vb.net

I have the following code that I want to use to display an image in a DataGridView cell: dgvInventory.Item(7, i).Value = My.Resources.ResourceManager.GetObject("picture") But instead of displaying the required image, it shows System.Drawing.Bitmap…
1
vote
0 answers

What would cause a data grid error on an image column only when deployed on a Windows 10 machine?

I have a C# windows forms app with a data grid. One column of the grid is an image column which I put a bitmap in. It works fine on the Windows 10 machine I developed it on and when I deploy it on Windows 7 machines, but on all other Windows 10…
1
vote
1 answer

Datagridview not changing image in cell

I am working with DataGridViewObject in my Windows form, using VB.NET. I have three columns that need to display icons. But, based on some info from row, that icons will be shown or not. My problem is that image won't change when I change its value.…
1
vote
1 answer

DataGridView ImageColumn Handle "Enter" key to perform Click

How to fire Click event of DataGridViewImageColumn when I press Enter. Currently when I press the Enter key on DataGridViewImageColumn it moves to next cell. Please help.
Parag Pathari
  • 281
  • 2
  • 5
  • 19
1
vote
1 answer

Generic error in GDI+ saving Datagridview data with images to XML

First off - thanks for all the information and snippets around here. Appreciate it. My problem; I'm trying to save some datagridview data, including images, to an XML file. Then trying to read it back in the grid again. I'm using a dataset & table…
Jelle O
  • 15
  • 4
1
vote
1 answer

"System out of memory exception" when try to load images in datagridview (VB Net)

I need to load around 70-100 images on datagridview (DatagridviewImageColumn) and I can do it but only loads 33 and then I get: "System out of memory exception" Memoria insuficiente. The images have high resolution (1600x2700). My code is: If…
user3822492
  • 145
  • 1
  • 11
1
vote
1 answer

DataGridView ImageColumn Displays PNG Picture withTransparent Background keeping previous Drawing in Picture location Winform VB.NET

I'm using ImageColumn in datagridview to view PNG Pictures saved in DB. Whenever I change tabs in my Form and go back to the Tab with DGV the PNG imgae transparent background keeps the drawing of the previous Control that was displayed in the same…
1
vote
1 answer

VB.net - Dynamically created column with an Image not displaying image in new row in datagridview

I am building a grid dynamically and want to have a delete image as the last displayed column. The image displays fine on the row I add, but the new row doesn't have the image. What am I missing? When I run the following code I get one row with…
HereGoes
  • 1,302
  • 1
  • 9
  • 14
1
vote
1 answer

DataGridViewImageColumn, images flickering

I have a DataGridView bound to a DataTable on my Windows Form. I want to insert an unbound DataGridViewImagecolumn to it and set the images according to the value of another column. Image is set in DataGidView_CellFormating event. Code is as…
1
2 3