MSFN Forum: working with external applications - MSFN Forum

Jump to content



Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

working with external applications VB2005 Rate Topic: -----

#1 User is offline   Cyber Axe 

  • Geek
  • Pip
  • Group: Members
  • Posts: 64
  • Joined: 13-December 03

Posted 06 September 2005 - 11:41 AM

i've written a wrapper for another app that basically just puts a window on top of another application so it is graphically more appealing

Public Class frmWrapper
    Private Sub frmWrapper_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        Dim Commands As String = Command()

        If Commands = Nothing Then
            MsgBox("You must specify the IPC File you wish to load.", MsgBoxStyle.Exclamation)
        ElseIf System.IO.File.Exists(Commands) = False Then
            MsgBox("Cannot find " + Chr(32) + System.IO.Path.GetFileName(Commands) + Chr(32) + ".", MsgBoxStyle.Exclamation)
        Else
            frmBackdrop.Show()
            frmOverlay.Show()
            Dim objWSH As Object
            objWSH = CreateObject("WScript.Shell")
            Commands = "WinIPAC.exe" + Chr(32) + Commands.Replace(Chr(34), Nothing)
            objWSH.Run(Commands, 1, True)
            frmOverlay.Close()
            frmBackdrop.Close()
        End If
        End
    End Sub
End Class


There are a few things I’d like to do but I don’t know if it’s possible or how to do them since I’ve not been able to find any info after searching

first of all one thing I’d like to do is after a certain period of time like 10 seconds or so if the application is still running then I get my wrapper to close it and then rerun until it doesn’t need to be closed (the program that’s being run should only take about 3 seconds to run and but if it returns an error such as a timeout it wont go away till the user clicks the close button)

Another thing I would like to do is the ability to resize and change the position of the window

and finally if its possible get text from a textbox that the window has so I can echo it on my wrapper instead of having to depend on overlaying a window this would make the above 2 things redundant since I wouldn’t need to wait nor would I need to manipulate the window position or size

Anyone got any info on how to do any of this?


Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users



All trademarks mentioned on this page are the property of their respective owners
Copyright © 2001 - 2011 msfn.org
Privacy Policy