C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Communities   Interview   Jobs   Projects   Offshore Development    
Silverlight Tutorials | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Revenue Sharing |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...

New Feature: Community Sites: Create your own .NET community website and start earning from Google AdSense ! It's Free !




Execute a new microsoft word


Posted Date: 21 Aug 2008    Resource Type: Articles    Category: General

Posted By: Ramesh Narayan       Member Level: Gold
Rating:     Points: 10



This article explains how to open a microsoft word using c# windows application.

Add the Reference :Microsoft Word 9.0 Object Library.
After adding the reference write the below code in button click.


Word.ApplicationClass WordApp = new Word.ApplicationClass();
object missing = System.Reflection.Missing.Value;
object fileName = "normal.dot";
object newTmple = false;
object docType = 0;
object isVisible = true;

Word.Document aDocmnt = WordApp.Documents.Add(ref fileName, ref newTemplate, ref docType, ref isVisible);

WordApp.Visible = true;

aDocmnt .Activate();




Responses


No responses found. Be the first to respond and make money from revenue sharing program.

Feedbacks      
Popular Tags   What are tags ?   Search Tags  
Execute a new microsoft word  .  

Post Feedback


This is a strictly moderated forum. Only approved messages will appear in the site. Please use 'Spell Check' in Google toolbar before you submit.
You must Sign In to post a response.
Next Resource: To read a XML file in vb.net
Previous Resource: Authenticating usernames and passwords from database
Return to Discussion Resource Index
Post New Resource
Category: General


Post resources and earn money!
 
Related Resources



dotNet Slackers   BizTalk Adaptors    Web Design

online optimum rewards

Contact Us    Privacy Policy    Terms Of Use