个人开发框架总结(五)
2009-05-05 08:27:11 来源:WEB开发网这里分两节,Header和Footer,每个节的Objects里可建立多个Label对象,使用不同的Key以便在程序里可以使用FindControl来查找,AutoCenter 属性指的是,标签居于报表表格的中间,AutoRight 是居右。ColumnConfigFile 引用的是对应的*.cls 文件,如:
<?xml version="1.0"?>
<ReportConfig xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<Title>消费明细报表</Title>
<ColumnConfigFile>frmConsumeDetailReport</ColumnConfigFile>
<PaperSize>
<Height>21</Height>
<Width>29.7</Width>
</PaperSize>
<Margins>
<Left>0.5</Left>
<Top>0.5</Top>
<Right>0.5</Right>
<Bottom>0.5</Bottom>
</Margins>
<Landscape>false</Landscape>
<DataColumns />
<Header>
<Objects>
<Label>
<Text></Text>
<HAlign>Center</HAlign>
<AutoCenter>True</AutoCenter>
<VAlign>Middle</VAlign>
<Font>
<Name>黑体</Name>
<Size>15</Size>
</Font>
<Key>Company</Key>
<Location>
<X>0</X>
<Y>0.2</Y>
</Location>
<Size>
<Width>0</Width>
<Height>0.6</Height>
</Size>
</Label>
<Label>
<Text></Text>
<HAlign>Center</HAlign>
<AutoCenter>True</AutoCenter>
<VAlign>Middle</VAlign>
<Font>
<Name>黑体</Name>
<Size>15</Size>
</Font>
<Key>Title</Key>
<Location>
<X>0</X>
<Y>0.8</Y>
</Location>
<Size>
<Width>0</Width>
<Height>0.6</Height>
</Size>
</Label>
<Label>
<Text>操作员:{0}</Text>
<HAlign>Left</HAlign>
<VAlign>Middle</VAlign>
<Key>Employee</Key>
<Location>
<X>0</X>
<Y>1.4</Y>
</Location>
<Size>
<Width>5</Width>
<Height>0.6</Height>
</Size>
</Label>
<Label>
<Text>="打印日期:" + Today.ToString("D")</Text>
<HAlign>Right</HAlign>
<AutoRight>True</AutoRight>
<VAlign>Middle</VAlign>
<Key>PrintDate</Key>
<Location>
<X>0</X>
<Y>1.4</Y>
</Location>
<Size>
<Width>5</Width>
<Height>0.6</Height>
</Size>
</Label>
</Objects>
<Height>2</Height>
</Header>
<Footer>
<Height>0.7</Height>
<Objects>
<Label>
<Text>="第" & Globals!PageNumber & "页 共" & Globals!TotalPages & "页"</Text>
<HAlign>Right</HAlign>
<AutoRight>True</AutoRight>
<VAlign>Middle</VAlign>
<Key>Page</Key>
<Location>
<X>0</X>
<Y>0.1</Y>
</Location>
<Size>
<Width>5</Width>
<Height>0.4</Height>
</Size>
</Label>
</Objects>
</Footer>
</ReportConfig>
更多精彩
赞助商链接