Good Morning,
I just recently started working wth the htmlView for grids as I need to represent rows in a more structured fashion. I love the fact you can define the layout using an HTML table like file and load it into the view definition. I have created this file and gone through the process, however, when running the following code:
I just recently started working wth the htmlView for grids as I need to represent rows in a more structured fashion. I love the fact you can define the layout using an HTML table like file and load it into the view definition. I have created this file and gone through the process, however, when running the following code:
protected void InitializeDataEntry()
{
htmlView = new HtmlViewDefinition();
htmlView.RowTemplate.ReadXml("/vcenter/address.html");
gridAddressEditList.ViewDefinition = htmlView;
}
I receive the following error:
Object reference not set to an instance of an object.
This is my address.html file. This seems to load fine:
<table>
<tr>
<td rowspan="2">Type</td>
<td>Address1</td>
<td>City</td>
<td rowspan="2">Postal Code</td>
</tr>
<tr>
<td>Address 2</td>
<td>State</td>
</tr>
</table>
I am new to using the viewDefinitions and thought I had followed the example code pretty closely. Could anyone point me in the right direction here?
Thanks,
Chris Eisnaugle