Results 1 to 2 of 2

Thread: Run Wordpad from a VB app

  1. #1

    Thread Starter
    New Member
    Join Date
    Nov 2001
    Location
    Manchester, UK
    Posts
    14

    Run Wordpad from a VB app

    Hi all,

    I have a small Vb application and I want to open Wordpad and transfer the text of a text box when you double click on it.

    Can anybody please help?

    Thanks a lot,

    Chris
    Chrysostomos Bourlis
    Application Developer

  2. #2
    Addicted Member
    Join Date
    Sep 2002
    Location
    Guwahati, Assam, India
    Posts
    131

    Unhappy So...

    VB Code:
    1. Private Sub Command1_Click()
    2.     Open App.Path & "\textfile.txt" For Output As #1
    3.         Print #1, Text1.Text
    4.     Close #1
    5.     Shell "notepad " & App.Path & "\textfile.txt", vbNormalFocus
    6. End Sub

    This is working fine with notepad. But not with wordpad, I don't know why. May be somebody else can help.
    I am new to VB...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width