Results 1 to 3 of 3

Thread: VB Executable

  1. #1

    Thread Starter
    New Member
    Join Date
    Jul 2001
    Location
    Ireland
    Posts
    4

    VB Executable

    Hi,

    Can anyone tell me how to have a VB executable open automatically once the Save As dialog box is closed.

    Also is there a way of 1) copying the file name from the Save As dialog box and inputting it into a text box on a different form and 2) how to set up a VB executable so that it sits in the systems tray when inactivate.

    Thanks,

    Cormac.

  2. #2
    Megatron
    Guest
    To open an EXE after the Save As dialog box is dismissed, just use the Shell statement after your ShowSave statement, e.g:
    VB Code:
    1. On Error Resume Next
    2. CmDlg.CancelError = True
    3. CmDlg.ShowSave
    4. If Err <> 32755 Then
    5.     Shell "C:\MyApp.exe", 1
    6. End If
    To copy the filename, just assign it like you would normally do:
    VB Code:
    1. On Error Resume Next
    2. CmDlg.CancelError = True
    3. CmDlg.ShowSave
    4. If Err <> 32755 Then
    5.     Form2.txtFileName = CmDlg.filename
    6. End If

  3. #3
    Megatron
    Guest
    See this tip for adding your program to the system tray.

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