更新2.4.2010 是的,这是一个老问题,但我想我会给出更新.所以,我再次使用ReportViewer,它仍然在初始加载时缓慢渲染.唯一的区别是SQL数据库位于报告服务器上.
更新3.16.2009
我已经完成了分析,并且不是SQL在第一次调用时使ReportViewer缓慢渲染.在第一次调用时,ReportViewer控件会锁定UI线程并使程序无响应.大约5秒后,ReportViewer将解锁UI线程并显示"正在生成报告",然后最终显示报告.我知道5秒并不多,但这不应该发生.我的同事在他的程序中执行相同的操作,并且ReportViewer会根据任何请求立即显示"正在生成报告".
唯一的区别是报告服务器位于一台服务器上,而数据位于另一台服务器上.但是,当我在SSRS中开发报告时,没有延迟.
UPDATE
我注意到只有第一次加载ReportViewer需要很长时间; 相同或不同报告的每个后续加载都会快速加载.
我有一个WinForms ReportViewer,我在远程处理模式下使用,当调用ReportViewer.RefreshReport()方法时,渲染最多可能需要30秒.但是,报告本身运行得很快.
这是设置ReportViewer的代码:
rvReport.ProcessingMode = ProcessingMode.Remote
rvReport.ShowParameterPrompts = False
rvReport.ServerReport.ReportServerUrl = New Uri(_reportServerURL)
rvReport.ServerReport.ReportPath = _reportPath
Run Code Online (Sandbox Code Playgroud)
这是ReportViewer最多需要30秒才能呈现的地方:
rvReport.RefreshReport()
Run Code Online (Sandbox Code Playgroud) 我有一个Ajax表单的搜索表单.在表单中有一个DropDownList,当更改时,应该刷新Ajax表单中的PartialView(通过GET请求).但是,在通过GET请求返回结果后,我不知道该怎么做才能刷新PartialView.
Search.aspx
<%@ Page Title="" Language="VB" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage" %>
<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
Search
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
<script type="text/javascript">
$(document).ready(function () {
$("#Sections").change(function () {
var section = $("#Sections").val();
var township = $("#Townships").val();
var range = $("#Ranges").val();
$.ajax({
type: "GET",
url: "Search/Search?section=" + section + "&township=" + township + "&range=" + range,
contentType: "application/json; charset=utf-8",
dataType: "html",
success: function (result) {
// What should I do here to refresh PartialView?
}
});
});
});
</script>
<h2>Search</h2>
<%--The line …Run Code Online (Sandbox Code Playgroud) ajax asp.net-mvc jquery asp.net-mvc-partialview asp.net-mvc-2
在.NET中开发桌面应用程序时,是否可以不要求.NET Framework?在.NET中开发软件是开发桌面应用程序的首选方式吗?软件公司用于开发桌面应用程序的最常用编程语言是什么?
是否基于您已安装的Windows操作系统假设.NET Framework的要求因此列出了Windows操作系统版本要求的原因?
我有一个Windows窗体,最初加载需要相当多的时间.但是,每个后续加载表单的请求都不会花费太长时间.有没有办法优化Form的加载时间?
我正在使用Jeditable进行就地编辑.我正在使用的控件之一就是select类型.当用户单击该字段时,将select生成以下控件:
<div id="status" class="editable_select">
<form>
<select name="value">
<option value="Active">Active</option>
<option value="Inactive">Inactive</option>
</select>
<button type="submit">Save</button>
<button type="cancel">Cancel</button>
</form>
</div>
Run Code Online (Sandbox Code Playgroud)
我想弄清楚的是如何使用jQuery来检测何时该select控件被更改,特别是因为它没有ID属性.
这是我到目前为止,但事件没有被触发:
$(document).ready(function () {
$('#status select').change(function () {
alert("Change Event Triggered On:" + $(this).attr("value"));
});
});
Run Code Online (Sandbox Code Playgroud)
UPDATE
更新到jQuery 1.4.2解决了我的问题以及使用Matt的解决方案.
在我的ReportViewer控件中,当我单击"打印布局"时,报表上的背景变为黑色.这一定是个bug.有解决方法吗?
一切都有效,除了列表没有出现在JFrame上.我不明白为什么我不能在没有声明新布局的情况下添加内容.
import javax.swing.*;
import javax.swing.event.ListSelectionEvent;
import javax.swing.event.ListSelectionListener;
import java.awt.*;
import java.awt.event.*;
public class Gui3 extends JFrame {
private JPanel mousepanel;
private JLabel statusbar;
private JList list;
private static String[] colornames = {"black","blue","red","white"};
private static Color[] colors = {Color.BLACK, Color.BLUE,Color.RED,Color.WHITE};
public Gui3(){
super("The title");
list = new JList(colornames);
list.setVisibleRowCount(4);
list.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
list.setFixedCellHeight(15);
list.setFixedCellWidth(100);
add(new JScrollPane(list));
list.addListSelectionListener(
new ListSelectionListener(){
public void valueChanged(ListSelectionEvent event){
Run Code Online (Sandbox Code Playgroud)
用户应该能够从列表中选择背景颜色,然后程序应该将背景更改为该颜色.但是不是......
mousepanel.setBackground(colors[list.getSelectedIndex()]);
}
}
);
mousepanel = new JPanel();
mousepanel.setBackground(Color.WHITE);
add(mousepanel, BorderLayout.CENTER);
statusbar = new JLabel("Default");
add(statusbar, BorderLayout.SOUTH);
HandlerClass handler …Run Code Online (Sandbox Code Playgroud) .net ×2
jquery ×2
reportviewer ×2
vb.net ×2
ajax ×1
asp.net-mvc ×1
c# ×1
dependencies ×1
frameworks ×1
java ×1
jeditable ×1
jframe ×1
jlist ×1
optimization ×1
performance ×1
swing ×1
winforms ×1