Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In with Facebook Sign In with Google Sign In with OpenID

Categories

We have migrated to a new platform! Please note that you will need to reset your password to log in (your credentials are still in-tact though). Please contact lee@programmersheaven.com if you have questions.
Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

I need help from you guyz...please,help me.....

gioannegioanne Posts: 8Member
im a graduating computer science student and one of our requirements is to make thesis...our topic is text auto-copying to microsoft word...can anyone help me make it???i will be using VB6 and im new with VB6...so,as you see it is very difficult....please help me....thanks...

Comments

  • rushenttrushentt Posts: 33Member
    : im a graduating computer science student and one of our requirements
    : is to make thesis...our topic is text auto-copying to microsoft
    : word...can anyone help me make it???i will be using VB6 and im new
    : with VB6...so,as you see it is very difficult....please help
    : me....thanks...
    :

    Here is an example from Microsoft's MSDN site:-
    1. Start a new Standard EXE project in Visual Basic. Form1 is created by default.
    2. On the Project menu, click References, and select "Microsoft Word 8.0 Object Library" (or "Microsoft Word 9.0 Object Library" if you are using Word 2000).
    3. Add a CommandButton to Form1.
    4. Add the following code to the Click event of the CommandButton:
    5.
    6. Dim oWordApp As Word.Application
    7.
    8. 'Start a new instance of Microsoft Word
    9. Set oWordApp = New Word.Application
    10.
    11. With oWordApp
    12.
    13. 'Create a new document
    14. .Documents.Add
    15.
    16. 'Add text to the document
    17. .Selection.TypeText Text:="one"
    18. .Selection.TypeParagraph
    19. .Selection.TypeText Text:="two"
    20. .Selection.TypeParagraph
    21. .Selection.TypeText Text:="three"
    22. 'Save the document
    23. .ActiveDocument.SaveAs FileName:="c:Doc1.doc", _
    24. FileFormat:=wdFormatDocument, LockComments:=False, _
    25. Password:="", AddToRecentFiles:=True, WritePassword _
    26. :="", ReadOnlyRecommended:=False, EmbedTrueTypeFonts:=False, _
    27. SaveNativePictureFormat:=False, SaveFormsData:=False, _
    28. SaveAsAOCELetter:= False
    29.
    30. End With
    31.
    32. 'Quit Word
    33. oWordApp.Quit
    34.
    35. 'Unload this form
    36. Unload Me
    37. Press F5 to run the program and click the CommandButton. When the program ends, examine the Word document ("C:doc1.doc") it created.
  • gioannegioanne Posts: 8Member
    thank you very much but i don't have Microsoft Word 8.0 Object Library" (or "Microsoft Word 9.0 Object Library" if you are using Word 2000). I only have Microsoft Word 11.0 Project Library...

Sign In or Register to comment.