sendinput problem

andriuskr

New member
Joined
Sep 21, 2004
Messages
1
Programming Experience
Beginner
hi ,

i'm trying to start this example, but 'window' and 'commandwindow' types aren't defined. I'll added reference " envdte " but the problem persists.

Here's the source...

plz, help

Imports System

Imports System.IO

Imports System.Enum

Module Module1

Sub Main()

End SubSub SendInputExample()

Dim DTE As EnvDTE.DTE

DTE = System.Runtime.

InteropServices.Marshal.GetActiveObject("VisualStudio.dte")

' Get a reference to the Command window.

Dim win As Window = DTE.Windows.Item(EnvDTE.Constants.vsWindowKindCommandWindow)

Dim CW As CommandWindow = win.Object

' Input a command into the Command window and execute it.

CW.SendInput("nav http://www.microsoft.com", False)

' Insert some information text into the Command window.

CW.OutputString("This URL takes you to the main Microsoft website.")

' Clear the contents of the Command window.

MsgBox("Clearing the Command window...")

CW.Clear()

EndSub





End
Module

 
Last edited:
Back
Top