<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Office Viewer Component</title>
	<atom:link href="http://www.ocxt.com/feed" rel="self" type="application/rss+xml" />
	<link>http://www.ocxt.com</link>
	<description>ActiveX document container for hosting Office documents and PDF (including Adobe PDF, Microsoft Word, Microsoft Excel, Microsoft PowerPoint, Microsoft Project and Microsoft Visio documents)</description>
	<lastBuildDate>Mon, 23 Apr 2012 14:43:04 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Edraw Office Viewer Component V8.0.0.365 Released</title>
		<link>http://www.ocxt.com/archives/92</link>
		<comments>http://www.ocxt.com/archives/92#comments</comments>
		<pubDate>Mon, 23 Apr 2012 06:01:51 +0000</pubDate>
		<dc:creator>office viewer</dc:creator>
				<category><![CDATA[Press Release]]></category>

		<guid isPermaLink="false">http://www.ocxt.com/?p=92</guid>
		<description><![CDATA[&#160; Edraw Office Viewer Component Acts as an ActiveX document container for embeding Office documents (including Microsoft Word, Microsoft Excel, Microsoft PowerPoint) in a custom form or Web page. The control is lightweight and flexible, and gives developers new possibilities for using Office in a custom solution. Download link: http://www.ocxt.com/download/OfficeOCXSetup.exe Online Demo: http://www.ocxt.com/online-demo You can [...]]]></description>
			<content:encoded><![CDATA[<p>&nbsp;</p>
<p><span style="font-family: Verdana; font-size: 16pt;"><a title="Office  Viewer Component" href="http://www.ocxt.com/download/OfficeOCXSetup.exe"><img style="border: 0px;" src="http://www.ocxt.com/images/officecomponent.png" alt="Office Viewer Component" width="463" height="195" border="0" /></a></span></p>
<p>Edraw Office Viewer Component Acts as an ActiveX document container for embeding Office documents (including Microsoft Word, Microsoft Excel, Microsoft PowerPoint) in a custom form or Web page. The control is lightweight and flexible, and gives developers new possibilities for using Office in a custom solution.</p>
<p>Download link: <a href="http://www.ocxt.com/download/OfficeOCXSetup.exe">http://www.ocxt.com/download/OfficeOCXSetup.exe</a></p>
<p>Online Demo: <a href="http://www.ocxt.com/online-demo">http://www.ocxt.com/online-demo</a></p>
<p><span style="font-family: Verdana;"><span style="text-decoration: none;"><a title="Download Office OCX" href="http://www.ocxt.com/download/OfficeOCXSetup.exe"><img style="border: 0px;" src="http://www.ocxt.com/images/btn_down.gif" alt="Free download Office Viewer Component" width="108" height="22" border="0" /></a></span><span style="text-decoration: none;"><a title="Buy Office Viewer Component" href="https://www.regnow.com/softsell/nph-softsell.cgi?item=14621-2"><img style="border: 0px;" src="http://www.ocxt.com/images/btn_buy.gif" alt="Purchase Office Viewer Component in a promotional price" width="108" height="22" border="0" /></a></span></span></p>
<p>You can find the sample projects and help document in the install folder. <a title="Office  Viewer Component" href="http://www.edrawsoft.com/officeviewer.php">Learn More</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ocxt.com/archives/92/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Edraw Viewer Component for Word V8.0.0.365 Released</title>
		<link>http://www.ocxt.com/archives/156</link>
		<comments>http://www.ocxt.com/archives/156#comments</comments>
		<pubDate>Sun, 22 Apr 2012 06:34:17 +0000</pubDate>
		<dc:creator>office viewer</dc:creator>
				<category><![CDATA[Press Release]]></category>

		<guid isPermaLink="false">http://www.ocxt.com/?p=156</guid>
		<description><![CDATA[Edraw Viewer Component for Word is the enhanced solution of office viewer and focus in the Microsoft Word. The word control is designed to handle specific issues that make using ActiveX documents from a non-top-level host window difficult, and serves as a starting place for constructing your own embedded word object file viewer or editor [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.edrawsoft.com/images/office/wordbox.gif" alt="word viewer" width="200" height="200" /></p>
<p>Edraw Viewer Component for Word is the enhanced solution of office viewer and focus in the Microsoft Word. The word control is designed to handle specific issues that make using ActiveX documents from a non-top-level host window difficult, and serves as a starting place for constructing your own embedded word object file viewer or editor as an ActiveX control.</p>
<p>It is a great solution for companies wishing to display read-only Word document data to their employees while restricting modifications to the underlying data. You can also display password protected Word documents without supplying passwords to your users &#8211; keep your confidential data safe and secure! With the Word component it is easy to upload or download file between server and client via HTTP/FTP.</p>
<p>It can be easily integrated to the modern integrated development environments like Visual C++, Visual Basic, C# or VB.NET, Acess, ASP.NET, Visual FoxPro, Delphi, PowerBuilder, and more.</p>
<p>Download link: <a href="http://www.edrawsoft.com/download/EDWordSetup.exe">http://www.edrawsoft.com/download/EDWordSetup.exe</a></p>
<p>Online Demo: <a href="http://www.ocxt.com/online-demo">http://www.ocxt.com/online-demo</a></p>
<p><span style="font-family: Verdana;"><span style="text-decoration: none;"><a title="Download Word OCX" href="http://www.edrawsoft.com/download/EDWordSetup.exe"><img style="border: 0px;" src="http://www.ocxt.com/images/btn_down.gif" alt="Free download Office Viewer Component" width="108" height="22" border="0" /></a></span><span style="text-decoration: none;"><a title="Buy Word Viewer Component" href="http://www.edrawsoft.com/edword.php#order"><img style="border: 0px;" src="http://www.ocxt.com/images/btn_buy.gif" alt="Purchase Office Viewer Component in a promotional price" width="108" height="22" border="0" /></a></span></span></p>
<p>The new component has also solved some known bugs in the previous version.</p>
<p><strong>What&#8217;s New:</strong></p>
<p>1. Supports to open multiple Word Instances in the different form or the IE tab.</p>
<p>2. Solved the toolbar disable issue when open a word instance outside of the component.</p>
<p>3. Solved the word menu flicker in the IE 7 and IE8.</p>
<p>4. Enabled more Word functions and buttons.</p>
<p>5. Added the method to disable the view right click menu.</p>
<p>6. Allows to disable the save, print and copy hot key (includes the F12 hot key).</p>
<p>7. Invoked the Word event in the component.</p>
<p>8. Supports to open the docx file in Word 2003 with 2007 compatibility package installed.</p>
<p>9. Supports to open the password and write password protected word document.</p>
<p>10. Added the protect type to allow only revisions or full protection.</p>
<p>11. Added the bookmark and revision operations.</p>
<p>12. Added the method to disable drag and drop function in the MS Word.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ocxt.com/archives/156/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Edraw Viewer Component for Excel V8.0.0.365 Released</title>
		<link>http://www.ocxt.com/archives/157</link>
		<comments>http://www.ocxt.com/archives/157#comments</comments>
		<pubDate>Sun, 22 Apr 2012 06:20:45 +0000</pubDate>
		<dc:creator>office viewer</dc:creator>
				<category><![CDATA[Press Release]]></category>

		<guid isPermaLink="false">http://www.ocxt.com/?p=157</guid>
		<description><![CDATA[Edraw Viewer Component for Excel is the enhanced solution of office viewer and focus in the Microsoft Excel. The excel control is designed to handle specific issues that make using ActiveX documents from a non-top-level host window difficult, and serves as a starting place for constructing your own embedded excel object file viewer or editor [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.edrawsoft.com/images/office/excelbox.gif" alt="Excel Viewer Component" width="200" height="200" /></p>
<p>Edraw Viewer Component for Excel is the enhanced solution of office viewer and focus in the Microsoft Excel. The excel control is designed to handle specific issues that make using ActiveX documents from a non-top-level host window difficult, and serves as a starting place for constructing your own embedded excel object file viewer or editor as an ActiveX control.</p>
<p>Download link: <a href="http://www.edrawsoft.com/download/EDExcelSetup.exe">http://www.edrawsoft.com/download/EDExcelSetup.exe</a></p>
<p>Online Demo: <a href="http://www.ocxt.com/online-demo">http://www.ocxt.com/online-demo</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ocxt.com/archives/157/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Edraw PDF Viewer Component V3.2.0.355 Released</title>
		<link>http://www.ocxt.com/archives/91</link>
		<comments>http://www.ocxt.com/archives/91#comments</comments>
		<pubDate>Sun, 11 Dec 2011 13:29:40 +0000</pubDate>
		<dc:creator>office viewer</dc:creator>
				<category><![CDATA[Press Release]]></category>

		<guid isPermaLink="false">http://www.ocxt.com/?p=91</guid>
		<description><![CDATA[PDF Viewer Component is a light weight ActiveX Control which enables your application to display and interact with PDF files. It is identical to Adobe Reader program and adds high speed viewing of PDF documents to your applications easily. Read-Only Support for PDF Viewer! It is a great solution for companies wishing to display read [...]]]></description>
			<content:encoded><![CDATA[<p><a title="PDF Viewer Component" href="http://www.ocxt.com/download/PDFViewerSetup.exe"><img style="border: 0px;" src="http://www.ocxt.com/images/pdfbox.gif" alt="PDF Viewer Component" width="200" height="188" border="0" /></a></p>
<p>PDF Viewer Component is a light weight ActiveX Control which enables your application to display and interact with PDF files. It is identical to Adobe Reader program and adds high speed viewing of PDF documents to your applications easily. Read-Only Support for PDF Viewer! It is a great solution for companies wishing to display read only PDF document to their employees while restricting save or save to the underlying data. The control is lightweight and flexible, and gives developers new possibilities for using PDF Reader in a custom solution.</p>
<p><span style="font-family: Verdana;"><span style="color: #ff0000;"><a title="PDF Viewer Component" href="http://www.ocxt.com/download/PDFViewerSetup.exe"><img src="http://www.ocxt.com/images/btn_down.gif" alt="Free download PDF Viewer Component" width="108" height="22" border="0" /></a><span style="font-family: Verdana; text-decoration: none;"><a title="Buy PDF Viewer Component" href="https://www.regnow.com/softsell/nph-softsell.cgi?item=14621-1"><img src="http://www.ocxt.com/images/btn_buy.gif" alt="Purchase PDF Viewer Component in a promotional price" width="100" height="22" border="0" /></a></span></span></span></p>
<div class="post-content"><span style="font-family: Verdana;"><span style="color: #ff0000;"><strong><span style="color: #ff9900;">Online Demo:</span></strong> </span><a title="test pdf viewer" href="http://www.ocxt.com/loadpdf.htm" target="_blank">PDF Viewer Component Online Demo</a><br />
<a href="http://www.ocxt.com/download/pdfviewerref.pdf">Download Printable Develop Manual</a></span></div>
<p style="margin-top: 10px; margin-bottom: 10; margin-right: 10px;"><span style="font-family: Verdana;"><strong>PDF Viewer Component Features</strong> </span></p>
<ol>
<li>
<div style="margin-top: 10px; margin-bottom: 10; margin-right: 10px;"><span style="font-family: Verdana;">Seamlessly use the Adobe Reader as the container to render the PDF files. 100% PDF format compatible.</span></div>
</li>
<li>
<div style="margin-top: 10px; margin-bottom: 10; margin-right: 10px;"><span style="font-family: Verdana;">HTTP/HTTPS Support. With the component it is easy to upload or download file between distant server and client via HTTP/FTP.</span></div>
</li>
<li>
<div style="margin-top: 10px; margin-bottom: 10; margin-right: 10px;"><span style="font-family: Verdana;">Show/Hide the Save Copy As button which is available in adobe tool bar.</span></div>
</li>
<li>
<div style="margin-top: 10px; margin-bottom: 10; margin-right: 10px;"><span style="font-family: Verdana;">Show/Hide the PDF Print button in adobe tool bar.</span></div>
</li>
<li>
<div style="margin-top: 10px; margin-bottom: 10; margin-right: 10px;"><span style="font-family: Verdana;">Show/Hide the scrollbar in PDF viewer.</span></div>
</li>
<li>
<div style="margin-top: 10px; margin-bottom: 10; margin-right: 10px;"><span style="font-family: Verdana;">Disable the right-click menu in adobe reader window.</span></div>
</li>
<li>
<div style="margin-top: 10px; margin-bottom: 10; margin-right: 10px;"><span style="font-family: Verdana;">Disable all the hot keys such as Save As, Print, Show/Hide Tool Bar and more.</span></div>
</li>
<li>
<div style="margin-top: 10px; margin-bottom: 10; margin-right: 10px;"><span style="font-family: Verdana;">The document control represents the PDF document and lets you open, close, save, print and<br />
navigate the PDF document programmatically. Support all the interfaces of Adobe PDF Reader such as zoom, search and navigate. </span></div>
</li>
<li>
<div style="margin-top: 10px; margin-bottom: 10; margin-right: 10px;"><span style="font-family: Verdana;">A standard ActiveX control which can be called from different programming languages, including C/C++, C#, Delphi, Visual Basic, ASP.NET etc.</span></div>
</li>
<li>
<div style="margin-top: 10px; margin-bottom: 10; margin-right: 10px;"><span style="font-family: Verdana;">Requires any edition of Adobe PDF Reader is included as part of the comprehensive PDF Viewer Component.</span></div>
</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://www.ocxt.com/archives/91/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to restore the disabled button in MS Word</title>
		<link>http://www.ocxt.com/archives/364</link>
		<comments>http://www.ocxt.com/archives/364#comments</comments>
		<pubDate>Thu, 09 Jun 2011 06:56:27 +0000</pubDate>
		<dc:creator>office viewer</dc:creator>
				<category><![CDATA[FAQ]]></category>

		<guid isPermaLink="false">http://www.ocxt.com/?p=364</guid>
		<description><![CDATA[Sometimes in Microsoft Word or Outlook the default template file normal.dot can become corrupt. To restore it do the following: 1. Close all office applications including Word and Outlook. 2. Use the normal.dot in the attachment. 3. Save it to your desktop to normal.dot. 4. Copy it to C:\Documents and Settings\&#60;youraccount&#62;\Application Data\Microsoft\Templates 5. Replace the [...]]]></description>
			<content:encoded><![CDATA[<p>Sometimes in Microsoft Word or Outlook the default template file normal.dot can become corrupt.</p>
<p>To restore it do the following:</p>
<p>1. Close all office applications including Word and Outlook.</p>
<p>2. Use the normal.dot in the attachment.</p>
<p>3. Save it to your desktop to normal.dot.</p>
<p>4. Copy it to</p>
<p>C:\Documents and Settings\&lt;youraccount&gt;\Application Data\Microsoft\Templates</p>
<p>5. Replace the file that is already in that folder.</p>
<p>When you then open Word or go to create a new message in Outlook 2003 the problem should be fixed.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ocxt.com/archives/364/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Host multiple Excel and Word components in a form</title>
		<link>http://www.ocxt.com/archives/36</link>
		<comments>http://www.ocxt.com/archives/36#comments</comments>
		<pubDate>Wed, 20 Apr 2011 09:15:37 +0000</pubDate>
		<dc:creator>office viewer</dc:creator>
				<category><![CDATA[Press Release]]></category>
		<category><![CDATA[Tech Support]]></category>

		<guid isPermaLink="false">http://www.ocxt.com/archives/36</guid>
		<description><![CDATA[You can host multiple office component in a form or you can open multiple office instance in your internet explore with Edraw Viewer Component version 7. The new version 7 has no toolbar-locked issues with multiple instances of Word or excel opened in several tabs or even inside single form. Note: you need set the [...]]]></description>
			<content:encoded><![CDATA[<p>You can host multiple office component in a form or you can open multiple office instance in your internet explore with Edraw Viewer Component version 7.</p>
<p>The new version 7 has no toolbar-locked  issues with multiple instances of Word or excel opened in several tabs or even inside single form.</p>
<p>Note: you need set the Frame hook policy as <em>SetOnFirstOpen</em> and Component activation policy as <em>KeepUIActiveOnAppDeactive in the previous version</em>. But it doesn&#8217;t work for the IE7 or IE8.</p>
<p><strong>Frame hook policy</strong><br />
To correctly handle activation when the host gains or loses foreground status, the ActiveX control uses a frame hook. By default, the hook is set when the control is created. In some situations, especially when the control is used from a multi-threaded UI host or when the control is nested in a container control like a Tab page in a .NET WinForm application, the parent of the control at create time may not be the correct window for the control to hook when it is running. In these situations, you can use the FrameHookPolicy property to reset the hook at a more suitable time. For example, if you build a .NET WinForm solution, set the FrameHookPolicy property to SetOnFirstOpen in the Properties window.<br />
<strong> </strong></p>
<p><strong>Component activation policy<br />
</strong>The sample control can support more than one instance of itself in a given host application. However, only one control can be active at a given time. This is a requirement of ActiveX Document hosting. To handle multiple instances in a single host, the control registers itself with a component manager. This lets the component manager keep track of the active control. Use the ActivationPolicy property to control how the embedded object is handled during component changes. The ActivationPolicy property can be set to one or more of the bit flags that are defined by the ActivationPolicy enumeration.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ocxt.com/archives/36/feed</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>Disable the Office Menu</title>
		<link>http://www.ocxt.com/archives/165</link>
		<comments>http://www.ocxt.com/archives/165#comments</comments>
		<pubDate>Tue, 12 Apr 2011 10:54:53 +0000</pubDate>
		<dc:creator>office viewer</dc:creator>
				<category><![CDATA[Tech Support]]></category>

		<guid isPermaLink="false">http://www.ocxt.com/?p=165</guid>
		<description><![CDATA[Edraw Office Viewer Components can disable the office main button and protect the opened document was modified by the end users. Only call the DisableFileCommand method in the BeforeDocumentOpen event and set the different enumerates. boolean DisableFileCommand([in] WdUIType UIType, [in] boolean Disable); UIType: The enum type need to disable in the UI. WdUIType. Disable: True to [...]]]></description>
			<content:encoded><![CDATA[<p>Edraw Office Viewer Components can disable the office main button and protect the opened document was modified by the end users. Only call the DisableFileCommand method in the BeforeDocumentOpen event and set the different enumerates.</p>
<p>boolean DisableFileCommand([in] WdUIType UIType, [in]<br />
boolean Disable);<br />
UIType: The enum type need to disable in the UI. WdUIType.<br />
Disable: True to disable the command button or menu item.<br />
enum WdUIType<br />
{<br />
wdUIDisalbeOfficeButton = 0&#215;00000001,<br />
wdUIDisalbeNew = 0&#215;00000002,<br />
wdUIDisalbeOpen = 0&#215;00000004,<br />
wdUIDisalbeUpgradeDocument = 0&#215;00000008,<br />
wdUIDisalbeSave = 0&#215;00000010,<br />
wdUIDisalbeSaveAs = 0&#215;00000020,<br />
wdUIDisalbeSendAsAttachment = 0&#215;00000040,<br />
wdUIDisalbeClose = 0&#215;00000100,<br />
wdUIDisalbePrint = 0&#215;00000200,<br />
wdUIDisalbePrintQuick = 0&#215;00000400,<br />
wdUIDisalbePrintPreview = 0&#215;00000800,<br />
wdUIDisalbeSaveAsMenu = 0&#215;00001000,<br />
wdUIDisalbePrepareMenu = 0&#215;00002000,<br />
wdUIDisalbePermissionRestrictMenu = 0&#215;00004000,<br />
wdUIDisalbeSendMenu = 0&#215;00008000,<br />
wdUIDisalbePublishMenu = 0&#215;00010000,<br />
wdUIDisalbeServerTasksMenu = 0&#215;00020000,<br />
wdUIDisalbeCopyButton = 0&#215;00040000,<br />
wdUIDisalbeCutButton = 0&#215;00080000,<br />
wdUIHideMenuHome = 0&#215;01000000,<br />
wdUIHideMenuInsert = 0&#215;02000000,<br />
wdUIHideMenuPageLayout = 0&#215;04000000,<br />
wdUIHideMenuReferences = 0&#215;08000000,<br />
wdUIHideMenuMailings = 0&#215;10000000,<br />
wdUIHideMenuReview = 0&#215;20000000,<br />
wdUIHideMenuView = 0&#215;40000000,<br />
wdUIHideMenuDeveloper = 0&#215;80000000,<br />
wdUIHideMenuAddIns = 0&#215;00100000,<br />
wdUIHideMenuFormat = 0&#215;00200000,<br />
wdUIHideMenuEdit = 0&#215;00400000,<br />
wdUIHideMenuTool = 0&#215;00800000,<br />
}WdUIType;<br />
Note: The component disabled the Office menu, New button and Open<br />
button in default.<br />
DWORD dwDisableCommand = wdUIDisalbeOfficeButton |<br />
wdUIDisalbeNew| wdUIDisalbeOpen;<br />
The function need be set in the BeforeDocumentOpened event.<br />
If you want to enable the three button, follow the samples.<br />
Example<br />
The following vb script shows how to enable the office main menu, new button and open<br />
button.<br />
Sub DocumentOpenedEvent ()<br />
Edword.DisableFileCommand 1 , false ‘wdUIDisalbeOfficeButton<br />
Edword.DisableFileCommand 2 , false ‘wdUIDisalbeNew<br />
Edword.DisableFileCommand 4 , false ‘wdUIDisalbeOpen<br />
End Sub<br />
SCRIPT FOR=OA1 EVENT= DocumentOpened ()<br />
DocumentOpenedEvent()<br />
SCRIPT<br />
The following vb script shows how to diable the saveas and save button.<br />
Sub DocumentOpenedEvent ()<br />
Edword.DisableFileCommand 16 , true ‘wdUIDisalbeSave<br />
Edword.DisableFileCommand 32 , true ‘wdUIDisalbeSaveAs<br />
End Sub<br />
SCRIPT FOR=OA1 EVENT= DocumentOpened ()<br />
DocumentOpenedEvent()<br />
SCRIPT</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ocxt.com/archives/165/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>How to insert HTML table into Word doc using Javascript?</title>
		<link>http://www.ocxt.com/archives/144</link>
		<comments>http://www.ocxt.com/archives/144#comments</comments>
		<pubDate>Thu, 03 Feb 2011 03:41:22 +0000</pubDate>
		<dc:creator>office viewer</dc:creator>
				<category><![CDATA[Office Automation]]></category>

		<guid isPermaLink="false">http://www.ocxt.com/?p=144</guid>
		<description><![CDATA[Use Edraw Office Viewer Component or Word Viewer Component to get the Document interface, then you can do it by the office automation. document.OA1.CreateNew(&#8220;Word.Document&#8221;); var objWord = document.OA1.ActiveDocument; var range = objWord.Range(0,0); var WTable = objWord.Tables.Add(range, 3,3); WTable.Cell(1,1).Range.Font.Name = &#8220;Times New Roman&#8221;; WTable.Cell(1,1).Range.Text = &#8220;examples 1&#8243;; WTable.Cell(1,2).Range.Font.Size = 18; WTable.Cell(1,2).Range.Bold = true; WTable.Cell(1,2).Range.Font.Italic = true; [...]]]></description>
			<content:encoded><![CDATA[<p>Use Edraw Office Viewer Component or Word Viewer Component to get the Document interface, then you can do it by the office automation.</p>
<p>document.OA1.CreateNew(&#8220;Word.Document&#8221;);<br />
var objWord = document.OA1.ActiveDocument;<br />
var range = objWord.Range(0,0);<br />
var WTable = objWord.Tables.Add(range, 3,3);<br />
WTable.Cell(1,1).Range.Font.Name = &#8220;Times New Roman&#8221;;</p>
<p>WTable.Cell(1,1).Range.Text = &#8220;examples 1&#8243;;<br />
WTable.Cell(1,2).Range.Font.Size = 18;<br />
WTable.Cell(1,2).Range.Bold = true;<br />
WTable.Cell(1,2).Range.Font.Italic = true;<br />
WTable.Cell(1,2).Range.Text = &#8220;examples 2&#8243;;<br />
WTable.Cell(2,1).Range.ParagraphFormat.Alignment = 1; // 0= Left, 1=Center, 2=Right<br />
WTable.Cell(2,1).Range.Font.Name = &#8220;Arial&#8221;;<br />
WTable.Cell(2,1).Range.Font.Size = 12;<br />
WTable.Cell(2,1).Range.Bold = false;<br />
WTable.Cell(2,1).Range.ParagraphFormat.Alignment = 2;<br />
WTable.Cell(3,3).Range.Font.Name = &#8220;Times New Roman&#8221;;<br />
WTable.Cell(3,3).Range.Font.Size = 14;<br />
WTable.Cell(3,3).Range.Bold = true;<br />
WTable.Cell(3,3).Range.Font.Underline = true;<br />
WTable.Cell(3,3).Range.ParagraphFormat.Alignment = 0;<br />
WTable.Cell(3,2).Range.Text = &#8220;examples 3&#8243;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ocxt.com/archives/144/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Embedding ms office in C# Forms</title>
		<link>http://www.ocxt.com/archives/40</link>
		<comments>http://www.ocxt.com/archives/40#comments</comments>
		<pubDate>Wed, 12 Jan 2011 08:34:09 +0000</pubDate>
		<dc:creator>office viewer</dc:creator>
				<category><![CDATA[Office Automation]]></category>
		<category><![CDATA[Tech Support]]></category>
		<category><![CDATA[embedding office]]></category>

		<guid isPermaLink="false">http://www.ocxt.com/archives/40</guid>
		<description><![CDATA[With Edraw Office Viewer Component, it&#8217;s easy to embed the ms office program in c# froms or html pages. Only drag it to your form, you can call some method to do the office automation directly such create a Word document or initialize an Excel sheet. 1. Download Edraw Office Viewer Component then install it. [...]]]></description>
			<content:encoded><![CDATA[<p>With Edraw Office Viewer Component, it&#8217;s easy to embed the ms office program in c# froms or html pages. Only drag it to your form, you can call some method to do the office automation directly such create a Word document or initialize an Excel sheet.</p>
<p>1. Download Edraw Office Viewer Component then install it. Or you can register the officeviewer.ocx using regsvr32 command.<br />
  C:\\WINNT\System32\regsvr32 OfficeVidewer.ocx<br />
2. On successful registration you would get message dialog.<br />
3. Add Office Viewer Active-X control on your form through customize toolbox window.<br />
4. Drag and drop component from toolbox on your form and resize as per requirement.<br />
5. Now add reference for &#8220;Microsoft Word Object Library 11.0&#8243; from add reference on solution explorer. Here I am using Word 2003, so object library version is 11.0.<br />
6. You can see all added reference on solution explorer as shown in figure. Two reference has been added for Edraw Office Viewer  Component (AxOfficeViewer and OfficeViewer) and three libraries for Office &amp; Word (Microsoft.Office.Core and Office and Word).<br />
7. Define a variable for word document in public section of form as<br />
   public Word.Document oDoc;<br />
8. Add following code for button click event<br />
private void button1_Click(object sender, System.EventArgs e)<br />
{<br />
     //Remove Office Viewer Component Title Bar and create a new Word document<br />
     axOfficeViewer1.Titlebar = false;<br />
     axOfficeViewer1.CreateNew(&#8220;Word.Document&#8221;);<br />
     axOfficeViewer1.Activate();<br />
     //Invoke Word properties<br />
     oDoc = (Word.Document)axOfficeViewer1.ActiveDocument;<br />
     oDoc.ActiveWindow.View.Type = Word.WdViewType.wdOutlineView;<br />
     oDoc.ActiveWindow.DisplayRulers = false;<br />
     oDoc.ActiveWindow.DisplayScreenTips = false;<br />
     oDoc.ActiveWindow.DisplayHorizontalScrollBar = false;<br />
     oDoc.ActiveWindow.DisplayVerticalRuler = false;<br />
     oDoc.ActiveWindow.DisplayVerticalScrollBar = true;<br />
}<br />
10. Now you can add text, format it, send mail do all functionalities.<br />
11. You can control all word functionalities to be made available or unavailable programmatically through code with all available objects, properties &amp; Methods of word.</p>
<p> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.ocxt.com/archives/40/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>(Fixed) CloseDoc error in the V7.5.0.331</title>
		<link>http://www.ocxt.com/archives/337</link>
		<comments>http://www.ocxt.com/archives/337#comments</comments>
		<pubDate>Thu, 06 Jan 2011 03:01:22 +0000</pubDate>
		<dc:creator>MIN KIM</dc:creator>
				<category><![CDATA[Tech Support]]></category>

		<guid isPermaLink="false">http://www.ocxt.com/?p=337</guid>
		<description><![CDATA[We are experiencing a problem with the Office Viewer component. We are using it embedded in a browser window (IE7). It is exhibiting some strange behavior under certain conditions. These are the steps to reproduce: If you open the browser window that has an instance of the office viewer on it, and use javascript to [...]]]></description>
			<content:encoded><![CDATA[<p>We are experiencing a problem with the Office Viewer component.  We are using it embedded in a browser window (IE7).  It is exhibiting some strange behavior under certain conditions.</p>
<p>These are the steps to reproduce:</p>
<p>If you open the browser window that has an instance of the office viewer on it, and use javascript to have the Office viewer open a word document<br />
Have another instance of WORD open in “stand alone” mode and  minimize it to the windows toolbar<br />
While the first browser window is opening and loading the WORD document, press on the WORD toolbar icon, so it maximizes and displays on the desktop </p>
<p>If you get the timing exactly right, so you open the minimized document just before the browser embedded version of WORD paints itself,  what you get is the two WORD documents are switched.  The browser window displays the document that was in the minimized copy of WORD, and the stand alone version of WORD displays the document that should have been displayed in the browser instance.</p>
<p>The automation interface is still manipulating the correct document, even though the document is opened in the wrong container.  For example, if you print the document using javascript in the browser, the document that gets printed is the one in the other window.</p>
<p>Have you ever come across this phenomenon?</p>
<p>I tried again, making absolutely sure that  it was 7.5.0.331 installed, as you suggested.  It is still happening.  It is important that you follow the sequence precisely….if you open word before you open the OfficeViewer demo app then everything is OK.  If you follow the following steps, it should occur:</p>
<p>1)      Reboot your machine</p>
<p>2)      Start the OfficeViewer HTML demo app by double clicking on officeviewer.htm in the samples folder.  Enable the OCX by choosing:  “allow blocked content”</p>
<p>3)      Open an existing WORD document in the OfficeViewer App</p>
<p>4)      Open a stand alone instance of word, and type a sentence in it.</p>
<p>5)      Choose the “close doc” option on the OfficeViewer.htm menu.  When the doc closes, instead of seeing an “empty” instance of WORD, you see the “blank” page.  This is how you can tell it is going to happen.  If you try the next test below, after hitting “Close doc” you will still see there is still an instance of word present with the toolbar, but no document..</p>
<p>6)      Close the browser window (using the x).  the stand alone instance of WORD will close, along with the browser window.</p>
<p>Clearly, in the above example, what has happened is the OfficeViewer has gotten mixed up, and is internally pointing to the stand alone instance of WORD, instead of the instance of word it was housing.  So when the browser window closed, it shut down WORD as well.</p>
<p>If you try the following sequence, you will not see the stand alone instance of Office close:</p>
<p>Test 2:</p>
<p>1)      Reboot your machine</p>
<p>2)      Open a stand alone instance of word and minimize it to the task bar</p>
<p>3)      Start the OfficeViewer HTML demo app by double clicking on officeviewer.htm in the samples folder.  Enable the OCX by cohoosing:  “allow blocked content”</p>
<p>4)      Open an existing WORD document in the OffiveViewer App</p>
<p>5)      Open a stand alone instance of word, and type a sentence in it.</p>
<p>6)      Choose the “close doc” option on the OfficeViewer.htm menu.  When the doc closes, unlike in the test above, you will still see WORD open with its toolbar, but no document.</p>
<p>7)      Close the browser window (using the x).  the browser window will close, but the stand alone instance of WORD will stay open</p>
<p>Clearly, having an instance of WORD open before you instantiate the OfficeViewer seems to keep the instance pointers correct.  In fact, in some situations, “windowless” WINWORD.EXE processes are left running by OfficeViewer, and if one of those is running, then the problem will not occur.  In fact, one of the possible work arounds I have considered is to actually start a copy of WINWORD.EXE if there is not one currently running…</p>
<p>Test 3:</p>
<p>After doing test 2, close both instances of WORD, and re-try test 1, without doing the reboot.  Everything works correctly.  As far as I can tell, once it works “correctly” it won’t happen again.</p>
<p>This is very reproducible on all of our corporate machines.  Would it be possible for you to try again, following those instructions exactly?  If you are absolutely sure it is not happening on your environments, then I will have to start looking at our machine configs….but I could literally spend weeks on it, and if it turns out that it in fact is happening on your machines as well, then it would be totally wasted time.  So I would really appreciate it if you could try again, following that precise sequence above…it could same me hundreds of  hours of effort!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ocxt.com/archives/337/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

