Click here to Skip to main content
15,911,360 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Get "Created" date from and Access table Pin
jzonthemtn2-Jul-08 5:59
jzonthemtn2-Jul-08 5:59 
QuestionProgress bar help Pin
Cory Kimble1-Jul-08 7:12
Cory Kimble1-Jul-08 7:12 
AnswerRe: Progress bar help Pin
jzonthemtn1-Jul-08 7:52
jzonthemtn1-Jul-08 7:52 
QuestionHow to Set Security? Pin
Trupti Mehta1-Jul-08 4:21
Trupti Mehta1-Jul-08 4:21 
QuestionHow to maximize third party app [modified] Pin
JLTBDY1-Jul-08 2:47
JLTBDY1-Jul-08 2:47 
AnswerRe: How to maximize third party app Pin
jzonthemtn1-Jul-08 4:54
jzonthemtn1-Jul-08 4:54 
GeneralRe: How to maximize third party app Pin
JLTBDY1-Jul-08 5:19
JLTBDY1-Jul-08 5:19 
GeneralRe: How to maximize third party app Pin
jzonthemtn1-Jul-08 5:34
jzonthemtn1-Jul-08 5:34 
Disclaimer: This code may not be 100% syntax-correct but it should get you started (particularly the call to FindWindowEx, my memory is unsure.)

In declarations:

<DllImport("user32.dll", SetLastError:=True, CharSet:=CharSet.Auto)> _
Private Shared Function FindWindowEx(ByVal parentHandle As IntPtr, _
                      ByVal childAfter As IntPtr, _
                      ByVal lclassName As String, _
                      ByVal windowTitle As String) As IntPtr

Private Declare Auto Function GetDesktopWindow Lib "user32.dll" () As IntPtr
End Function

<DllImport("user32.dll", SetLastError:=True, CharSet:=CharSet.Auto)> _
Private Shared Function ShowWindow(ByVal hwnd As IntPtr, ByVal nCmdShow As Int32) As Boolean
End Function


In code, before where the screen shot is taken:

' Get the window's handle
Dim WindowTitle as String = "Notepad"
Dim WindowToMax as IntPtr = FindWindowEx(GetDesktopWindow(), IntPtr.Zero, IntPtr.Zero, "WindowTitle")

' Maximize it
ShowWindow(WindowToMax, 3) ' 3 is for ShowMaximized


I use FindWindowEx to find the window to maximize (the window with "Notepad" as the title). Then pass the window's handle to ShowWindow(). There's a lot of examples out there for FindWindowEx and ShowWindow in case you need more.
GeneralRe: How to maximize third party app Pin
JLTBDY7-Jul-08 7:28
JLTBDY7-Jul-08 7:28 
GeneralRe: How to maximize third party app Pin
jzonthemtn7-Jul-08 8:11
jzonthemtn7-Jul-08 8:11 
GeneralRe: How to maximize third party app Pin
JLTBDY8-Jul-08 12:00
JLTBDY8-Jul-08 12:00 
GeneralRe: How to maximize third party app Pin
jzonthemtn8-Jul-08 12:19
jzonthemtn8-Jul-08 12:19 
AnswerRe: How to maximize third party app Pin
JLTBDY9-Jul-08 6:07
JLTBDY9-Jul-08 6:07 
GeneralRe: How to maximize third party app Pin
jzonthemtn10-Jul-08 3:17
jzonthemtn10-Jul-08 3:17 
Questionsql datareader Pin
Ebube1-Jul-08 2:45
Ebube1-Jul-08 2:45 
AnswerRe: sql datareader Pin
paas1-Jul-08 3:26
paas1-Jul-08 3:26 
GeneralRe: sql datareader Pin
Ebube1-Jul-08 5:05
Ebube1-Jul-08 5:05 
GeneralRe: sql datareader Pin
paas1-Jul-08 5:18
paas1-Jul-08 5:18 
GeneralRe: sql datareader Pin
Ebube1-Jul-08 5:33
Ebube1-Jul-08 5:33 
GeneralRe: sql datareader Pin
Ebube1-Jul-08 6:04
Ebube1-Jul-08 6:04 
GeneralRe: sql datareader Pin
paas1-Jul-08 7:03
paas1-Jul-08 7:03 
GeneralRe: sql datareader Pin
Ebube1-Jul-08 16:09
Ebube1-Jul-08 16:09 
QuestionInsert text at the end of the current mail in outlook Reply mail window using vb.net Pin
~Khatri Mitesh~1-Jul-08 2:42
~Khatri Mitesh~1-Jul-08 2:42 
Questionchecking image in a picturebox Pin
Ahamed Azeem1-Jul-08 2:33
Ahamed Azeem1-Jul-08 2:33 
AnswerRe: checking image in a picturebox Pin
Tom Deketelaere1-Jul-08 4:19
professionalTom Deketelaere1-Jul-08 4:19 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.