473,395 Members | 1,915 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

DataGrid Display Graphic

I'm trying to get a single column DataGrid to display a graphic. I set up
the DataGrid template to display and image. This is what I've tried based on
the example I found:

Dim dgiItem As DataGridItem

For Each dgiItem In DataGrid1.Items

With DirectCast(dgiItem.FindControl("Image1"), WebControls.Image)

.ImageUrl = sAddPath & "AT1.JPG"

.DataBind()

End With

Next

What am I doing wrong?

Regards,

Don Buchanan
Nov 20 '05 #1
2 1237
Cor
Hi Don,
Dim dgiItem As DataGridItem
For Each dgiItem In DataGrid1.Items
With DirectCast(dgiItem.FindControl("Image1"), WebControls.Image)
.ImageUrl = sAddPath & "AT1.JPG"
.DataBind()
End With
Next
What am I doing wrong?


Did you check if a datagrid column can hold graphic data as far as I know it
can not
Did you check if you can add items to a datagrid, as far as I know you can
only bind them using an underlaying table

Cor
Nov 20 '05 #2
Cor
Hi Don,
Dim dgiItem As DataGridItem
For Each dgiItem In DataGrid1.Items
With DirectCast(dgiItem.FindControl("Image1"), WebControls.Image)
.ImageUrl = sAddPath & "AT1.JPG"
.DataBind()
End With
Next
What am I doing wrong?


Did you check if a datagrid column can hold graphic data as far as I know it
can not
Did you check if you can add items to a datagrid, as far as I know you can
only bind them using an underlaying table

Cor
Nov 20 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: chantao | last post by:
Hi I am a total novice to PHP/MYSQL. Please help How do I display a graphic file (e.g. archit01.jpg) as a background i a table of a PHP page if I have a table called gfx and th gfx_ID=archit0...
3
by: Diego TERCERO | last post by:
Hi... I'm working on a tool for editing text resources for a family of software product my company produces. These text resources are found in a SQL Server database, in a table called...
4
by: DrData | last post by:
I'm working on an ASP.Net application written in C#. On one page, there are several datagrid controls used to display, edit and delete detail records relating to the master record also displayed on...
0
by: Don Buchanan | last post by:
I'm trying to get a single column DataGrid to display a graphic. I set up the DataGrid template to display and image. This is what I've tried based on the example I found: Dim dgiItem As...
3
by: Datatable Dataset Datagrid help | last post by:
Hi I am somewhat confused, I am new at VB.net I use XML data, I have a datagrid, I created a datatable so that I can create a custom format like true is this graphic false is this graphic and...
3
by: TPhelps | last post by:
I have a sample of an unbound (autogeneratecolumns is true) sortable/pagable datagrid that works. I want to change one of the columns to a hyperlink. The examples I find use a bound column. I...
4
by: simon | last post by:
hello, i am displaying a dataset in a datagrid, for one of the values being displayed it either comes back as a 1 or a 0, which is currently bound to a column in the datagrid what i'd like to do...
2
by: Good Man | last post by:
Hi there I have quite a bit of experience with CSS but I am stumped by the following: http://www.electricphase.com/example/example1.php (uses http://www.electricphase.com/example/test1.css) ...
0
by: bobdydd | last post by:
Hi All I am using the common dialog routine to insert a pathway to a jpeg To display on a form that worked perfectly well in Access 2000. Now using the same setup everything works as before...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.