如何从代码隐藏运行 telerik RadWindow
我正在尝试从代码后面运行 telerik rad 窗口。但我有一些问题。 我不知道这是否重要,但我正在尝试从 rad 网格的编辑模式下单击的按钮运行 rad 窗口。
RadWindow window1 = new RadWindow();
window1.NavigateUrl = "http://www.google.com";
window1.VisibleOnPageLoad = true;
window1.ID = "RadWindow1";
window1.Width = 500;
window1.Height = 300;
window1.VisibleOnPageLoad = true;
rwm_WindowManager.Windows.Add(window1);
在页面上,我还有放入 RadAjaxPanel
中的 RadAjaxManager
和 rwm_WindowManager
。
问题是这个 rad 窗口永远不会出现。没有错误,但也没有 rad 窗口。
I am trying to run telerik rad window from code behind. But I have some issues.
I don't know is it important but I am trying to run rad window from button clicked in edit mode from rad grid.
RadWindow window1 = new RadWindow();
window1.NavigateUrl = "http://www.google.com";
window1.VisibleOnPageLoad = true;
window1.ID = "RadWindow1";
window1.Width = 500;
window1.Height = 300;
window1.VisibleOnPageLoad = true;
rwm_WindowManager.Windows.Add(window1);
On the page I also have RadAjaxManager
and rwm_WindowManager
I put in RadAjaxPanel
.
Problem is that this rad window never shows up. There are no errors but no rad window also.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
........................
将 RadWindowManager 放入 RadAjaxPanel 中。
........................
put your RadWindowManager inside RadAjaxPanel.
我刚刚遇到了类似的问题。我这样解决了它:
我的应用程序使用 RadAjax,这使得
VisibleOnPageLoad
属性出现问题,所以我完全避免它。I just had a similar issue. I resolved it like so:
My applications use RadAjax which makes the
VisibleOnPageLoad
property problematic, so I avoid it altogether.看一下这里:如何刷新父页面关闭 radwindow 时网格? 并检查我的答案中的链接。这种方法更加简洁,并且可以避免一些不必要的回发。
Take a look here: How to refresh parent page grid when close radwindow? and examine the links from my answer. The approach is much cleaner and will spare you a couple of unnecessary postbacks.