.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

back ground image in css for a datalist

Posted By:      Posted Date: October 01, 2010    Points: 0   Category :ASP.Net


i have a datalist which i am using to display like tabs. I am using the css to set the background images for each tab. But for some reason the images do not come in the tabs. I am not sure why. please check the code below and let me know what i am doing wrong.

 the css:

    BORDER-RIGHT: gray 1px solid;
 BORDER-TOP: #B0reDE  1px solid;
 FONT-WEIGHT: normal;
 BORDER-LEFT: blue 1px solid;
 BORDER-BOTTOM: blue 1px solid;
 font-family: Verdana, Arial, Helvetica, sans-serif;
 font-size: 10px;
 font-weight: bold;
 text-align: center;
 padding-top: 3px;
 padding-right: 9px;
 padding-bottom: 3px;
 padding-left: 9px;

the datalist code

<asp:DataList ID="tabs" RepeatDirection="Horizontal"  runat="server" CellPadding="0"
                CellSpacing="0" ItemStyle-CssClass="inactivetab" SelectedItemStyle-CssClass="activetab">

View Complete Post

More Related Resource Links

datalist image slide show problem


hi friends

i am binding  images dynamically(back end)for a datalist .iam applying a slideshow for it .I am getting a problem to apply slideshow for dyanmically binded images.If the define in a div statically it working perfectly

for example pls go through my code below:

<script type="text/javascript">
$(document).ready(function() {
        fx: 'scrollLeft' // choose your transition type, ex: fade, scrollUp, shuffle, etc...

<div class="slideshow">
        <img src="images/30_dummy.jpg" width="200" height="200" />
        <img src="images/aquarius.gif" width="200" height="200" />
        <img src="images/star.gif" width="200" height="200" />
        <img src="images/the-proud-indian-flag-1.jpg" width="200" height="200" />

I above code works perfectly and the slide show e

Dynamic Image Buttons in GridView not doing partial post back

Hi Gurus - Create a gridview with AllowPaging and AllowSorting = true- On page load, I bind it to datasource (in my case a webservice) - On gridview's rowcreated event, I dynamically add image buttons on the header of the grid for sorting (up/down arrows). On header I have column name and the image. I removed the Column name default sorting link. So user can now only click the image button for sorting.-  Call sorting method This works perfectly fine without AJAX. The paging, sorting works fine. Also when I apply AJAX the paging works fine. But the sorting is doing a full post back instead of partial postback. I have my gridview within UpdatePanel and Triggeres is set on gridview sill it doesn't work.ASPX Code<form id="form1" runat="server"> <asp:ScriptManager ID="ScriptManager1" runat="server" /> <div> <asp:Label ID="lblAccount" runat="server" Text="Account #: "></asp:Label> <asp:TextBox ID="txtAccountNumber" runat="server">12203A30</asp:TextBox> <asp:Button ID="cmdGo" runat="server" Text="Go" OnClick="cmdGo_Click" /><br /> <asp:UpdatePanel ID="UpdatePanel1" runat="server"> &l

Rebind datalist after upload an image using jquery


Hi, I'm having a problem with using jquery to trigger a datalist rebind here, hope people here could help me with it. 

I'm using a jquery plugin called uploadify to upload images to my database. I'd like my datalist to be auto-rebind after the images' been uploaded so people could see the changes immediately. Also because this is a feature for admin there is a delete button in the datalist. I used updatePanel for this.  

I put __doPostBack('" + upnlUploaded.ClientID + "','') to the javascript so when Images have been uploaded the update panel will postback. 

I also have the following two lines to make it working... 

<asp:UpdatePanel ID="upnlUploaded" runat="server" UpdateMode="Conditional" OnLoad="upnlUploaded_Load"> <%--upnlUploaded_Load   --%>

       <asp:UpdatePanel ID="upnlUploaded" runat="server" UpdateMode="Conditional" OnLoad="upnlUploaded_Load"

        protected void upnlUploaded_Load(object sender, EventArgs e)

How to retrive client name ,Field , and Image from Database and show in datalist?


hi experts,

i wanat to display Client Name, Field and  image in datalist. Stored Procedure like this

ALTER proc [dbo].[get_clients_services]
SELECT     Clients.ClientName AS Client, Fields.FieldName AS Field, ServiceType.ServiceType AS Services, ServiceType.Servicelink AS Link, 
                      Clients.ClientLogo AS Logo
FROM         Clients INNER JOIN

image in datalist who are one over another


hi there
i am creating a new web site : http://www.my-restaurantbooking.com/ricerca.aspx
as you can see in the 4th element i have a list of images, but every image is over another!!!

here the code i used to do it:

<asp:DataList ID="DL_Immagini" runat="server" DataSourceID="Sql_IMG" HorizontalAlign="Left" RepeatColumns="10" RepeatDirection="Horizontal"> <ItemTemplate> <asp:HyperLink ID="HYP_IMG" runat="server" alt="gallery thumbnail" class="preview" ImageUrl='<%# Eval("NomeIMG") %>' NavigateUrl='<%# Eval("Ingrandimento") %>' target="_blank" Width="30" Height="30"></asp:HyperLink> </ItemTemplate> </asp:DataList>

i tried to set width and height, but i does not work
i tried also to remove CSS..but nothing

image button in datalist


i have stored the image url  in the database.

i have a image button in datalist.i want that when i click that imagebutton i get its url of that particular row.


Datalist not displaying image from database


My database table contains the image file path which will be stored from a
file upload control.The image path in the table will be like "C:\Projects\projectname\projectfolder\Files\1_129308367798080000_images1.jpg"

I am trying to display that image through a datalist control as follows
<asp:DataList ID="cobrandlogolist" runat="server">
                <asp:Image id="CobrandLogo" ImageUrl='<%# DataBinder.Eval(Container.DataItem, "CobrandLogo") %>' Height="100px" Width="100px"


and i am retrieving the image names from the db and assigning as datasource of this datalist in the load event as follows

    DataTable dt = new DataTable();

Converting raw RGBA data back into an image.


I have been using a programme called Momento (which is a photobook programme - see www.momento.com.au if relevant).  With out boring you with the details I have lost all of my original data and am unable to recover it.

The programme did store image cache files in my application data and these appear to be related to the original picutres.  These files have names like 0dfc15fead0908ed2176d0d46e165614 and dont have file extensions.  Some are quite large - 3-4 GB which is consistent with the original pics.  There is also a file of thumb cache and these are DAT files.  Neither open with Momento.  I have been in touch with Momento support and they are unable to assist me other than to tell me the image cache files are raw RGBA data.

Obviously what I need to know is can I convert these files back to some sort of image and if so how and/or what programme can I use?  Is there a techincal service that could do it for me for a fee?

Thanks in advance


Built-in Functions - Text and Image Functions in SQL Server

Text and image functions operate on TEXT, NTEXT and IMAGE data types. These data types are deprecated with SQL Server 2005 and should be replaced by VARCHAR(MAX), NVARCHAR(MAX) and VARBINARY(MAX) when possible. Alternatively you can also consider storing large string values using XML data type. Text and image functions are nondeterministic.

Future versions of SQL Server will not support TEXT, NTEXT and IMAGE data types. Columns with TEXT / NTEXT data type do not support commonly used string functions such as LEN, LEFT, RIGHT, etc. Furthermore, due to the large size of TEXT data you''re likely to see performance issues if you store such data in the database. However, at times you can''t help but use the TEXT / NTEXT / IMAGE data types (for example when supporting 3rd party databases when you cannot change the schema) - this is when text and image functions come in handy.

Program for Format Conversion of An Image

.NET provides extensive support for image conversion. Any image can be processed from one format to another. Most common formats to which .NET have support for are .BMP, .EMF, .GIF, .ICO, .JPG, .PNG, .TIF and .WMF.

Configuring Profile Image Export in SharePoint 2010

It's no secret that I am thrilled with the new social features of SharePoint 2010. I am most excited about the new Profile Picture handling. I strongly believe that the more we can show the faces of our colleagues to one another the more connected we will feel. Clearly Microsoft feels that way as witnessed by the many features that make use of the Profile Image like the Activity Feed and Colleagues list

Built-in Functions - Text and Image Functions

Text and image functions operate on TEXT, NTEXT and IMAGE data types. These data types are deprecated with SQL Server 2005 and should be replaced by VARCHAR(MAX), NVARCHAR(MAX) and VARBINARY(MAX) when possible. Alternatively you can also consider storing large string values using XML data type. Text and image functions are nondeterministic.

ASP.Net Upload Image to MS Access Database

As you learnt from the previous articles to upload image to the SQL Database in ASP.Net 2.0 and stream that image into the memory to retrieve it from the database and display it on the web page. In this article you will learn how to upload images to the MS Access database in ASP.Net 2.0

First of all create an Access Database and place it in the App_Data folder of ASP.Net web site project. Then create a table "tblImg" with the following fields:

Get pixel format, raw format, property id list and property items image in VB.net - C#.net.

n this simple article you will learn that how we can get pixel format, raw format, property id list and property items image in VB and C#.net.

Get Pixel Format:

Image consists of pixels to get the format of the pixel we have a property named pixel format. This property returns an enumeration of pixel format. This enumeration tells the pixel format.

To demonstrate make a window application. Drag one button and a picture box on form.

Now write the following code on Button click event:

Post back puzzle


Hi, I have a website where the user makes a selection from a combo box and it then fills a couple text boxes with text based upon the selection. I'm sure as you know it could take a second for the text to appear in the text box due to the post back. I know there is no way to make it instantanious, so what I would like to do it fill the text box with somthing like "Loading Info..." so the user does not type in it while the information is loading.

If you would like to see what I mean please go to this page: www.epiclinks.com/create.aspx and mess around with the combo boxes and You'll see what I mean.

What I would like to do is have it do a post back to write "Loading Info..." and then do another post back to fill it in based upon their selection. How would I do this?

I'm up for anything, so if you have a better solution than that please let me know.


slideshow image gallary using jQuery



i need a gallary like following link.


actually,i bound multiple image in a gridview using handler(.ashx).

for example,in one dep_id(1),there are 6 image and i need to slideing one by one.

could some one help me,how i can do like this?

i think is it easy in jquery.

please someone help me.

Thanking you.

Can't display an image from the database



My database has a products table that has images stored in a varbinary(MAX) column.

I'm trying to display product information in a repeater and trying to display the images as well by using a GenericHandler class but I can't get the image to show up in my page.

Here is my Handler.ashx class:

Public Class Handler
    Implements System.Web.IHttpHandler

    Sub ProcessRequest(ByVal context As HttpContext) Implements IHttpHandler.ProcessRequest

        '== Set up the response settings
        context.Response.ContentType = "image/gif"
        context.Response.BufferOutput = False

        Dim id As Integer = -1
        Dim stream As Stream = Nothing
        If Not String.IsNullOrEmpty(context.Request.QueryString("id")) Then
            id = context.Request.QueryString("id")
            stream = GetImage(id)
        End If

        Const buffersize As Integer = 1024 * 16
        Dim buffer(buffersize) As Byte
        'byte[] buffer = new byte[buffersize];
        Dim count As Integer = stream.Read(buffer, 0, buffersize)

        While count > 0
            context.Response.OutputStream.Write(buffer, 0, count)
            count = stream.Read(buffer, 0, buffersize)
        End While


ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend