<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="GetImageUrl.aspx.cs" Inherits="ZYDN.Web.system.GetImageUrl" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>截图调用</title>
    <link href="../../system/skins/CSS/main.css" rel="stylesheet" type="text/css" />
    <link href="../../system/skins/CSS/Sys.css" rel="stylesheet" type="text/css" />
    <script src="../JS/JFramework.js" language="javascript" type="text/javascript"></script>
    <script src="../JS/Sys.js" language="javascript" type="text/javascript"></script>
    <script language="javascript" type="text/javascript">
    var objAjax=new JAjax();
        function GetAddress()
          {
            var address = location.href;
            var index = address.indexOf('/',8);
            var newaddress = address.substring(0,index);
            var objResponse=new JHttpResponse();
            objResponse.write("abc","");
            var out = objAjax.getText("post","?type=GetUid",objResponse,null);  
            if(out!=null&&out!="")
            {
                document.getElementById("Button1").disabled = "disabled";
                csharpActiveX.Setparm(newaddress,"SIMG"+out);
            }
          }
          
          
          function UseUpImage()
          {
            var objResponse=new JHttpResponse();
            objResponse.write("abc","");
            var out = objAjax.getText("post","?type=UseUpImage",objResponse,null);  
            if(out!=null&&out!="")
            {
                window.returnValue = out;
                window.close();
            }
            else
            {
                alert("无图片可调用");
            }
          }
    </script>
</head>
<body>

    <div style="width:380px; height:40px; margin:20px auto; text-align:center;">
    <object id="csharpActiveX" classid="clsid:2DAF5EE9-CC82-4d50-918E-0F92494D1D51" codebase="Screenshot.cab#version=1,0,0,3"></object>
    <input id="Button1" type="button" value="截图" onclick="GetAddress()" />
    <input id="Button2" type="button" value="调用" onclick="UseUpImage()" />
    </div>
    <div style="width:380px; height:100px; margin:1px auto;">
        为了能正常的使用截图功能，请点击浏览器“工具”→“Internet选项”→“安全”→“可信站点”→“站点”→把下面服务器验证（https:）设为非选中然后再把我们的网站添加进“网站”框中最后点击“关闭”
        →右下角“默认级别”设为低→“应用”→“确定”
        好了刷新一下页面，弹出的对话点击安装，安装好后就可以使用该功能了。<br />
        截图的使用：截图好后点击绿色的勾，然后点击调用就是您刚才所截的图。<br />
       <span style="color:Red">注意：请确保您的电脑安装了.NET Framework2.0</span> 
    </div>
</body>
</html>
