⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 readme.html

📁 JavaScript调用Delphi过程
💻 HTML
字号:
<!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" lang="en" xml:lang="en">

<head>

	<title>
		DelphiDabbler.com: Article #22 Demo Readme
	</title>

	<style type="text/css">
		<!--
		body {
			margin: 1em;
			padding: 0;
			font-family: Verdana, Arial, sans-serif;
			font-size: 9pt;
			line-height: 150%;
		}
		h1 {
			margin: 0 0 1em 0;
			padding: 0.5em;
			border: 1px silver solid;
			background-color: #EEEEEE;
			font-size: 13pt;
			font-weight: bold;
			text-align: center;
		}
		h2 {
			margin: 1em 0 0 0;
			padding: 0;
			padding-bottom: 6px;
			border-bottom: 1px silver solid;
			font-size: 11pt;
			font-weight: bold;
		}
		h3 {
			margin: 0.5em 0 0 0;
			padding: 0;
			font-size: 9pt;
			font-weight: bold;
		}
		p {
			margin: 0.5em 0 0 0;
			padding: 0;
		}
		ul, ol {
			margin: 0.5em 0 0 3em;
			padding: 0;
		}
		ul {
			list-style-type: square;
		}
		ul.spaced li, ol.spaced li {
			margin-top: 0.5em;
		}
		code {
			font-family: "Courier New", Courier, monospace;
		}
		span.articlename {
			color: navy;
			font-style: italic;
		}
		div.endnotes {
			margin: 1.5em 0 0 0;
			padding: 1em 0 0 0;
			border-top: 1px silver solid;
		}
		div.comments {
			font-style: italic;
		}
		div.copyright,
		div.copyright a:link,
		div.copyright a:visited,
		div.copyright a:active {
			margin: 1em 0 0 0;
			color: gray;
			font-size: 8pt;
			text-align: right;
		}
		-->
	</style>

</head>

<body>

<h1>
	DelphiDabbler.com<br />
	Demo Project for Article #22:<br />
	<span class="articlename">&quot;How to call Delphi code from scripts running
	in a TWebBrowser&quot;</span>
</h1>

<p>
	This ReadMe file explains how to use the demo source code that accompanies
	the article
	&quot;<a href="http://www.delphidabbler.com/articles?article=22">How to call
	Delphi code from scripts running in a TWebBrowser</a>&quot;.
</p>

<p>
	Included in the download are the following files:
</p>

<ul>
	<li>
		<code>Article22.dat</code> &ndash; data file used by demo program.
	</li>
	<li>
		<code>Article22.dpr</code> &ndash; project file for demo program.
	</li>
	<li>
		<code>Article22.html</code> &ndash; HTML document displayed in
		<var>TWebBrowser</var> control.
	</li>
	<li>
		<code>Article22.res</code> &ndash; icon etc for demo program.
	</li>
	<li>
		<code>Article22.tlb</code> &ndash; type library used to define external
		object interface.
	</li>
	<li>
		<code>Article22_TLB.pas</code> &ndash; file generated by type library
		editor.
	</li>
	<li>
		<code>FmDemo.pas/.dfm</code> &ndash; demo program's main form.
	</li>
	<li>
		<code>IntfDocHostUIHandler.pas</code> &ndash; defines
		<var>IDocHostUIHandler</var> interface and associated structures.
	</li>
	<li>
		<code>UExternalContainer.pas</code> &ndash; defines
		<var>IDocHostUIHandler</var> and <var>IOleClientSite</var>
		implementation that provides external object to <var>TWebBrowser</var>.
	</li>
	<li>
		<code>UMyExternal.pas</code> &ndash; implementation of external object.
	</li>
	<li>
		<code>UNulContainer.pas</code> &ndash; defines do nothing implementation
		of <var>IDocHostUIHandler</var> and <var>IOleClientSite</var> and
		registers client site with <var>TWebBrowser</var>.
	</li>
</ul>

<p>
	To use the demo start Delphi and load <code>Article22.dpr</code>. Compile
	the program and run it. <code>Article22.html</code> is displayed in the
	browser control. Click on one of the program names displayed in the list and
	its name and precis will appear in the bordered box at the bottom of the
	display.
</p>

<p>
	Once the program has been tested, examine the code in the various units.
</p>

<p>
	The code is targetted at Delphi 7 and has been tested on Windows XP Pro SP2
	using Internet Explorer 6
</p>

<div class="endnotes">

	<div class="comments">
		If you have any comments on the article or this source code, or if you
		have found a bug, please let me know. You can contact me via my website
		<a href="http://www.delphidabbler.com/contact" target="_blank">
		contact page</a>.
	</div>

	<div class="copyright">
		Copyright &copy; 2005-2006, P D Johnson,
		<a href="http://www.delphidabbler.com" target="_blank">
		www.delphidabbler.com</a>
	</div>

</div>

</body>

</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -