Hi friz,
I want to convert word document (with all formatings & images) to a PDF file.
How i can achive this.
Please Help.
jacky kwok - 16 Oct 2007 03:08 GMT
> Hi friz,
>
[quoted text clipped - 3 lines]
>
> Please Help.
I do not sure winword itself to have such function or not. I do not use
winword since winword2000.
Several methods you can change a word document to PDF:
1. install Adobe Acrobat.
2. using Open Office. Use Open office to open winword document, then
export to PDF (export to PDF is built function of Open Office writer).

Signature
Jacky Kwok
jacky@alumni_DOT_cuhk_DOT_edu_DOT_hk
Mads Bondo Dydensborg - 17 Oct 2007 11:14 GMT
> 2. using Open Office. Use Open office to open winword document, then
> export to PDF (export to PDF is built function of Open Office writer).
Yes, and if you use open offices UNO interface (
http://wiki.services.openoffice.org/wiki/Uno ) you can drive it from within
your programs.
Regards
Mads

Signature
Med venlig hilsen/Regards
Systemudvikler/Systemsdeveloper cand.scient.dat, Ph.d., Mads Bondo
Dydensborg
Dansk BiblioteksCenter A/S, Tempovej 7-11, 2750 Ballerup, Tlf. +45 44 86 77
34
adaandeve - 29 Nov 2007 18:32 GMT
> Hi friz,
>
[quoted text clipped - 3 lines]
>
> Please Help.
adaandeve - 29 Nov 2007 18:35 GMT
How did you end up doing it? I'd like to do it too.
Laura
> Hi friz,
>
[quoted text clipped - 3 lines]
>
> Please Help.
Bob Eaton - 30 Nov 2007 03:34 GMT
> I want to convert word document (with all formatings & images) to a PDF
> file.
If you have Office/Word 2007, you can install the PDF plug-in and save
directly from within Word.
Below is a snippet of VB.Net code that will do the conversion using the Word
(2007) PIAs.
Bob
+------------------cut here------------------+
Imports System.Windows.Forms
Imports Word = Microsoft.Office.Interop.Word
Imports System.Runtime.InteropServices ' for Marshal
Imports System.IO ' Path
Module ConvertDocToPdf
Sub Main()
Dim openFileDialog As New OpenFileDialog
openFileDialog.Multiselect = True
openFileDialog.Filter = "All Word Documents
(*.docx;*.docm;*.dotx;*.dotm;*.doc;*.dot;*.htm;*.html;*.rtf;*.mht;*.mhtml;*.xml)|*.docx;
*.docm; *.dotx; *.dotm; *.doc; *.dot; *.htm; *.html; *.rtf; *.mht; *.mhtml;
*.xml|All files (*.*)|*.*"
If (openFileDialog.ShowDialog() = DialogResult.OK) Then
Dim wdSaveFormat As Word.WdSaveFormat =
Microsoft.Office.Interop.Word.WdSaveFormat.wdFormatPDF
Dim wrdApp As New Word.Application
Try
Dim oDocFilename As Object
For Each oDocFilename In openFileDialog.FileNames
Dim wrdDoc As Word.Document = wrdApp.Documents.Open(oDocFilename)
Dim oToFilename As Object = String.Format("{0}\{1}",
Path.GetDirectoryName(oDocFilename), _
Path.GetFileNameWithoutExtension(oDocFilename) + ".pdf")
wrdDoc.SaveAs(oToFilename, wdSaveFormat)
wrdDoc.Close()
Next
Catch ex As Exception
MessageBox.Show(ex.Message)
Finally
wrdApp.Quit()
Marshal.ReleaseComObject(wrdApp)
End Try
End If
End Sub
End Module