Datagrid and header with image

Ask a Question related to ASP.NET General, Design and Development.

  1. #1

    Default Datagrid and header with image

    Iam trying to implement sorting.
    I know how to display a button in the header of an datagrid. How can i
    display an image with down arrow and uparrow along the side of button on the
    header.
    Any sample pointers will be of great help.

    Thanks




    sunil Guest

  2. Similar Questions and Discussions

    1. How to use image as pannel header?
      hi all, we here here are building a flex application for Laingorourke UK's domestic housing solution, which will cater the dynamic needs of...
    2. Sorting when there's an image in the header doesn't seem to work....
      I've got a datagrid that works just ducky. I then put in the headers image and now my sort event doesn't get fired. If I take out just the...
    3. Image in header column (not replacing column header text)
      I have a sortable (asc/desc) datagrid and would like to add a small arrow icon (down/up) next to the column header text to improve the UI. Is this...
    4. Image Header
      Hi! I don't know if this is ok, so can somebody give me some explanation. I made some php script to get Header from http request. When I...
    5. DataGrid with image in the Column Header
      Is it possible to have both an image and text as part of a Column Header in a DataGrid? Ideally, you could click on either sort the column. I have...
  3. #2

    Default Re: Datagrid and header with image

    You will need to create a label control in th itemcreatedevent eventhandler,
    set the font to webdings and the text to 5 for down 6 for up then add the
    label to the header cell
    if(listitemtype == header)
    Label arrow = new Label
    Label.Font = webdings
    Label.Text = 5
    e.item.cells[1].controls.add(label)
    you will also need to store the sort direction or get the control, check the
    text and flip it depending on what it is.

    this is pseudo code by the way.

    "sunil" <sunil_godiyal@yahoo.com> wrote in message
    news:uA$ZHzKRDHA.2204@TK2MSFTNGP12.phx.gbl...
    > Iam trying to implement sorting.
    > I know how to display a button in the header of an datagrid. How can i
    > display an image with down arrow and uparrow along the side of button on
    the
    > header.
    > Any sample pointers will be of great help.
    >
    > Thanks
    >
    >
    >
    >

    Alvin Bruney Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139