ASP中动态使用MicrosoftReport详解
1.在解决方案中添加新项目数据集-mydbDataSet.xsd,在数据集里添加所要用到的表或根据需要制作新表。
2.在设计页面中拉入一个MicrosoftReportViewer,设计新报表,按照报表向导根据自己的需要选择报表的数据源和数据项,完成新报表report1.rdlc的制作。在源码中如下(“考核成绩”为数据集中的一个表)
<rsweb:ReportViewer ID="ReportViewer1" runat="server" Font-Names="Verdana"
Font-Size="8pt" Height="400px" Width="930px">
<LocalReport ReportPath="Report1.rdlc">
<DataSources>
<rsweb:ReportDataSource DataSourceId="ObjectDataSource1"
Name="mydbDataSet_考核成绩" />
</DataSources>
</LocalReport>
</rsweb:ReportViewer>
3.进入代码页面
string strsql = "select * from XX where XX";
SqlDataAdapter da = new SqlDataAdapter(strsql, Connection);
DataSet dsrp = new DataSet();
da.Fill(dsrp, "考核成绩");
ReportDataSource reportDataSource1 = new ReportDataSource("m
相关文档:
最近几周,在博客、Twitter和论坛上如火如荼地展开了一场讨论。讨论的内容是:开发人员是否应该使用或学习ASP.NET MVC。从“不推荐学习”到“所有ASP.NET开发人员都应该学习”,各种不同的观点层出不穷。InfoQ对其中部分讨论内容进行了总结。
Rob Conerey(SubSonic之父,目前是微软ASP.NET MVC团队的 ......
Set xlApp = CreateObject("Excel.Application")
xlApp.DisplayAlerts = false '不显示警告
'xlApp.Application = false ......
set conn=server.createobject("adodb.connection")
conn.open "driver={microsoft access driver (*.mdb)};dbq=F:\\ajaxpro\\App_Data\\server.mdb"
Dim StrSQL,RS
StrSQL="SELECT*from Manager WHERE ID='"&username&"'"
StrSQL=StrSQL&"AND Pin='"&passwor ......
<%
set rs=server.CreateObject(”ADODB.recordset”)
sql =”select * from 表”
rs.open sql,conn,1,1
page=cint(request(”page”))
n=rs.RecordCount
rs.pagesize=12
m=cint(rs.pagecount)
if page=”" then
page=1
elseif page<1 then
page=1
end if
if cint(r ......