Results 1 to 3 of 3

Thread: DataGrid Formatting

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Oct 2000
    Location
    Chesterfield, UK
    Posts
    298

    DataGrid Formatting

    Two things :

    In the datagrid is there a way to add images into one of the cells??

    Also is there a way to make all the text in the cells bold??

    Any help would be much appreciated.

    Regards,


    Matt

  2. #2
    Hyperactive Member
    Join Date
    Mar 2002
    Location
    Dublin (Ireland)
    Posts
    304
    try this:
    Dim ts2 As New DataGridTableStyle()
    ts2.MappingName = "Mydataset"
    Dim p1 As New DataGridTextBoxColumn()
    p1.MappingName = "Reference"
    p1.HeaderText = " Reference"
    p1.Width = 80
    p1.NullText = ""
    p1.TextBox.Text = FontStyle.Bold
    ts2.GridColumnStyles.Add(p1)
    DataGrid1.TableStyles.Add(ts2)



    Images mmmmmmmmm..... not too sure about that, however if the datacolumn it is bound to is an image and you just use the default mapping that might work although I've not tried that

    as in:

    DataGrid1.SetDataBinding(ds1, "Mydataset") and that contained an image column it would be interesting to see how the system handled it

  3. #3

    Thread Starter
    Hyperactive Member
    Join Date
    Oct 2000
    Location
    Chesterfield, UK
    Posts
    298
    Cheers,

    I will give the image thing a go and see what happens.

    Regards,


    Matt.

Posting Permissions

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



Click Here to Expand Forum to Full Width