Microsoft
Software
Hardware
Network
Question : change the width of a BoundField column in DataView USING C#
I am trying to find a way to control the width of a column in a dataview table. As I build the table is there somehting I can set to change the size of columns?
here is the code that is working, but I need to some how add a control to change the width to a value I want.
public void BuildGridViewStructure
(Dictionary<string, string> lv_AllGridCols
, Dictionary<string, bool> lv_ShowHideGridViewColDict
ionary
, Dictionary<string, string> lv_ColumnHeadingTextDictio
nary
, System.Web.UI.WebControls.
GridView lv_GridView)
{
lv_GridView.AutoGenerateCo
lumns = false;
// this is columns
System.Web.UI.WebControls.
BoundField
nameColumn;
//build the datagrid columns programatically
//and populate the data
foreach (KeyValuePair<string, string> AllGridPair in lv_AllGridCols)
{
nameColumn = new BoundField();
nameColumn.DataField = AllGridPair.Key;
nameColumn.HeaderText = lv_ColumnHeadingTextDictio
nary[AllGr
idPair.Key
];
nameColumn.Visible = lv_ShowHideGridViewColDict
ionary[All
GridPair.K
ey];
// have some code in here to allow me to change the width of the column
lv_GridView.Columns.Add(na
meColumn);
}
}
Answer : change the width of a BoundField column in DataView USING C#
Do you have write permissions on that particular calendar? We have a number of calendars which are strictly controled as to who can update them, could be the same situation in your location.
Random Solutions
Move exchange storage group to another drive
reamviewer 5
I want to put a small instruction in the middle of my SharePoint survey. I want to say "If you answered "No" to any of the questions above then please answer the questions below. How?
How do I allow users on SBS 2008 to install programs?
Microsoft Exchange Outlook Anywhere SSL Issue
Create a "Batch Number" in SQL Server 2000 for import of sales orders
syslink Router
Registry, Winlogon, KEY_WOW64_64KEY errors
how to create a css file to format xml file
outlook not running rules