询问者
asp控件的方法中调用window.open,无法打开新页面。

问题
-
http://gz.56it168.com/NetStudy/Home_OnlyForExns.aspx?UserId=OTg0MDQ%3d&tdsourcetag=s_pcqq_aiomsg
的点击打印,打印页面不弹出,怎么办?
程序代码中在asp控件加入onClike方法,在里面调用 Response.Write("<script>alert(\"如果您看不到打印页面,说明页面已经被拦截,请设置浏览器!\");window.open('" + FileName + "');</script>");却无法打开已经有的网页,也不弹出alert定义的说明。
全部回复
-
你好,
根据你的,我做一个小的Demo, 是可以工作的,我不知道是不是浏览器的一些设置导致的问题。 你可以检查一下浏览器的设置,看是不是禁用了JS.
Beset regards,
Zhanglong
MSDN Community Support
Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com. -
你好,
你可以下载下面的链接。
https://1drv.ms/u/s!AlvaNEnglADDqiuiIQdPcMwRLQwi
Best regards,
Zhanglong
MSDN Community Support
Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com. -
你好,
我使用的VS 2017 企业版, IIS的版本是10.0.17134.1 。
Best regards,
Zhanglong
MSDN Community Support
Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.