내 페이지에 Google 문서 뷰어를 삽입하려고합니다. 는 여기에서 Test.aspx 코드입니다 :Google 문서 뷰어에서 ASP.Net 페이지 내에서 자바 스크립트 오류가 발생합니다.
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="test.aspx.cs" Inherits="Web_Application.test" %>
<!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>
</head>
<body>
<iframe id="documentLoader" src="https://docs.google.com/viewer?embedded=true&url=http://view.samurajdata.se/license.pdf"
style="width:100%; height:800px;">
</iframe>
</body>
</html>
여기
내 test.aspx.cs이
namespace Web_Application
{
public partial class test : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
}
}
}
내가 오류를 얻을 것 같은
'Line: 409
Error: Unable to get value of the property 'k': object is null or undefined'
또는
'Line: 458
Error: Unable to get value of the property 'a': object is null or undefined'
로하는 Google 문서 뷰어 온라인 j에서 왔습니다. avascript 리소스 ...
그래서 헤더에 스크립트를 삽입하고 작동했습니다. 하지만 문제는, 내가 이것을 사용자 정의 컨트롤이나 마스터 페이지에서 상속받은 페이지에서 다시 수행하면 이러한 오류가 다시 발생한다는 것입니다.
어떻게 해결할 수 있습니까?
감사합니다.
당신이 당신의 자신의에서이 문제에 대한 해결책을 발견하는 경우, 자신의 대답이 질문을 업데이트하십시오 및 접수로 표시합니다. 이렇게하면 낮은 수락 등급도 향상됩니다. –