Results 1 to 2 of 2

Thread: [Resolved]-Datagrid formatting in code behind

Threaded View

  1. #1

    Thread Starter
    Fanatic Member venerable bede's Avatar
    Join Date
    Sep 2002
    Location
    The mystic land of Geordies
    Posts
    1,018

    [Resolved]-Datagrid formatting in code behind

    In my code behind I add a coloumn to a datgrid :
    Code:
    lBlockUsedUp.DataField = "BlockUsedUp"
    lBlockUsedUp.HeaderText = "Blocks Used Up"
    lBlockUsedUp.ItemStyle.Width = New Unit(300)
    dgBiopsyLocation.Columns.Add(lBlockUsedUp)
    I then bind in code with :
    Code:
     dgBiopsyLocation.DataSource = iDataset.Tables("ArrBiopsyLocation")
    dgBiopsyLocation.DataBind()
    The problem I am having is that the field "BlockUsedUp", which is a bit field in SQL SERVER always shows "FALSE" when the value = 0. I want this to be "" if it is 0 and I want to do it all in my code behind.

    Can anyone help ?
    Last edited by venerable bede; Jul 1st, 2004 at 05:44 AM.

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