how to print a doc file
                
                    nt                
                
                    Member Posts: 160                
            
                        
            
                    hi, anyone knows how i can add or print a doc file from a report?
thanks.
                thanks.
0                
            Comments
- 
            Sorry, if you want to create DOC file from the Report, you can use Save as HTML and open it in word and save it as DOC, I do not know automatic way (but can exist)...0
 - 
            You could use the Automation Data Type.
Create the following vars:Name DataType Subtype Word Automation 'Microsoft Word x.0 Object Library'.Application Selection Automation 'Microsoft Word x.0 Object Library'.Selection
Then you have to code something like the following:CREATE(Word); Word.Documents.Add(); //if you want to use a template; Template has to be a text var //Template := 'C:\template.doc'; //Word.Documents.Add(Template); Selection := Word.Selection; Selection.TypeText('Test'); Word.Visible := TRUE; //to print the document on preset printer Word.PrintOut;
Of course you can use a template, so you just have to fill in the needed information.0 - 
            thanks tim.
the "word.selection" what value will have?0 - 
            The "Selection" is just an alias for "Word.Selection". But the Selection var has to know which selection it should control. So you have to assign the Word.Selection to the Selection var.
You could also control everything with the Word var.Selection := Word.Selection; Selection.TypeText('Test');is the same asWord.Selection.TypeText('Test');0 - 
            ok thanks0
 
Categories
- All Categories
 - 73 General
 - 73 Announcements
 - 66.6K Microsoft Dynamics NAV
 - 18.7K NAV Three Tier
 - 38.4K NAV/Navision Classic Client
 - 3.6K Navision Attain
 - 2.4K Navision Financials
 - 116 Navision DOS
 - 851 Navision e-Commerce
 - 1K NAV Tips & Tricks
 - 772 NAV Dutch speaking only
 - 617 NAV Courses, Exams & Certification
 - 2K Microsoft Dynamics-Other
 - 1.5K Dynamics AX
 - 323 Dynamics CRM
 - 111 Dynamics GP
 - 10 Dynamics SL
 - 1.5K Other
 - 990 SQL General
 - 383 SQL Performance
 - 34 SQL Tips & Tricks
 - 35 Design Patterns (General & Best Practices)
 - 1 Architectural Patterns
 - 10 Design Patterns
 - 5 Implementation Patterns
 - 53 3rd Party Products, Services & Events
 - 1.6K General
 - 1.1K General Chat
 - 1.6K Website
 - 83 Testing
 - 1.2K Download section
 - 23 How Tos section
 - 252 Feedback
 - 12 NAV TechDays 2013 Sessions
 - 13 NAV TechDays 2012 Sessions
 
