Move And Re-size A Window That Has BorderStyle = None With MediaPlayer As Child

Jul 10, 2011

What I am doing is making a Media Player, but I am making it to be some sort like BS Player.

The Video part of the player is on its own with no border and then there is going to be a separate Form for the controls. (I might need help with that later) But the first thing that I have to do is make the window movable and re-sizable by dragging the Media Player (WMP). WMP is taking up the whole screen of the Form so there is no where to click on the original Form. If possible, I would like it to show contents while dragging, ignoring the Windows Appearance and Performance. If that can't be done or is to much work, I will settle for just the border of the Form being showed while moved.

For re-sizing, the media player has to stay the same size as the form, but it also has to stay the same Ratio of the video. So as long as I can specify the current height and width of the window and also get then get the width while the window is being re-sized, I can get the height that the window needs to be by using this formula.

Window.y / Window.x * Sized Window.x = New Window.y .

I know that may sound complicated or maybe I am making it harder then it actually is, this is just how I know how to do it. I will explain what each variable in the Formula means.

Window.y is the current height of the window

Window.x is the current width of the window

Sized Window.x is the width of the window while it is being re-sized

New Window.y is the final height for the new size of the window

View 11 Replies


ADVERTISEMENT

How To Move Window If BorderStyle Is None

Oct 31, 2009

I have a huge problem. The Formborderstyle of the form is None but I need to move the window just like if it had one. You know drag the form somewhere else.

View 3 Replies

Increase Size/move When The Form's Size Changes?

Sep 6, 2011

I want to to increase size/move when the form's size changes....

View 4 Replies

VS 2008 - Child Window - Yet Not Child Window

Aug 23, 2009

I have a 3rd party program that puts up a pop up box and asks the user for input. In Spy++ the original program (I'll refer to this as Window A from now on) is a top level window, and the popup (Window B) is also a parent window. However, when I use FindWindow(Nothing, "Captcha Challenge") it returns 0. I've also used a code snippet from the forums

[Code]....

View 1 Replies

Find The Handle Of The Child Window For The Yes Button In The User Account Control Window?

Mar 20, 2010

I am trying to find the handle of the child window for the Yes button in the User Account Control window so i can click it. This window has a structure with a few child windows with the same name.

Dim hwnd As IntPtr = FindWindow(Nothing, "User Account Control")
Dim hwnd2 As IntPtr = FindWindowEx(hwnd, 0, "DirectUIHWND", vbNullString)
Dim hwnd3 As IntPtr = FindWindowEx(hwnd2, 0, "CtrlNotifySink", vbNullString)
Dim hwnd4 As IntPtr = FindWindowEx(hwnd3, 0, "Button", "&Yes")

There are multiple CtrNotifySink with its own Button child window or other child windows. How do i search thru the different CtrNotifySink window to find the one that contain the Yes button so i can send a click to it? I do need to find it before i can send a click, right? because i try just sending it to the main window with sendmessage and nothing happen.I even try sending it directly to the handle found by spy++ of the yes button with bm click but nothing happen?

View 2 Replies

Wpf - Fire A Custom Event From A Child Window Back To Parent Window?

Feb 13, 2012

I am looking to close the application when I click a cancel button in a login page, but I don't want to do it in such a way that Window 2 closes itself, but by sending some notification to Main Window, and Main Window closes the application. Here's the code that I have so far:

(in loginPage)

Public Event CloseApp As EventHandler
Private Sub CancelButton_Click(sender As System.Object, e As System.Windows.RoutedEventArgs) Handles CancelButton.Click

[Code]....

View 1 Replies

Child Window Open Inside Of The Main Window Form?

Oct 12, 2010

I have create a project with one main form window and also i have to use a number of other forms as well. now i want to open these other forms inside the main window and not outside. I'm using Visual Studio .NET 2010 as developing environment.

View 1 Replies

Prevent Minimize Of Child Window When Parent Window Minimizes?

Dec 19, 2011

If I show a new non-modal child window using .Show(frmParent), and then the parent window is minimized, the child will get minimized automatically as well.

View 2 Replies

IE Window - Size The Window, But Not Change The Windows Location On The Screen?

Jun 21, 2011

im using vb.net to open IE and go to a website... i can figure out how to size the window, but not change the windows location on the screen... how can i make the IE window position always 0,0

Dim oIE As Object
Dim hWnd As Long
oIE = CreateObject("InternetExplorer.Application")[code].....

View 3 Replies

Change The Size Of The Button With Size Of The Window?

May 15, 2012

How do I connect the size of any button in the form to the size of the window so that it would change proportionally to the size of the window?

View 1 Replies

VS 2005 Setwindowpos For Top Most Window Making Window Size Zero?

Oct 5, 2011

I have the following function that should make the window always on top of other applications.

Private Declare Function SetWindowPos Lib "user32" _
(ByVal handle As Long, ByVal hWndInsertAfter As Long, ByVal x As Long, ByVal y As Long, _
ByVal cx As Long, ByVal cy As Long, ByVal wFlags As Long) As Long

[Code]....

The problem is that it reduces the window size so that you can only see the title bar and min/max/close buttons. Also, even that does not stay on top of other windows.

I have used this function before on a windows 7 machine (instead of xp which this one is on) and it worked fine.

View 4 Replies

Get Size And Location Of Top Window Foreground Window?

Aug 14, 2009

I want to take a snapshot of the foreground window without using print screen key. So far the only think i can do with the foreground window is get its title but If i can get the size and location then I can get cordinates on where to set capture with graphics.copyfromscreen.

View 3 Replies

Setwindowpos For Top Most Window Making Window Size Zero?

Oct 5, 2011

I have the following function that should make the window always on top of other applications.

Code:
Private Declare Function SetWindowPos Lib "user32" _
(ByVal handle As Long, ByVal hWndInsertAfter As Long, ByVal x As Long, ByVal y As Long, _
ByVal cx As Long, ByVal cy As Long, ByVal wFlags As Long) As Long

[code].....

The problem is that it reduces the window size so that you can only see the title bar and min/max/close buttons. Also, even that does not stay on top of other windows.I have used this function before on a windows 7 machine (instead of xp which this one is on) and it worked fine.

View 3 Replies

Mdi Child Form Move When Tab Chanage

Jul 28, 2010

I am using MDI Parent and Child form. In MDI Child form there are 2 Tab Pages when i navigate Tab Pages the whole MDI Child move up and down. In MDI Parent both horizontal and vertical scroll bar. I dont want that the MDI Chil window is moving.

View 1 Replies

Cannot Move Child Controls In Tab Control Pages

Feb 24, 2011

I've created a tab control and on one of the pages I added a button, but I cannot move the button around with the mouse!? I can change the buttons position within the tab control page using the property Location and I can size the button using the mouse and the button is NOT locked. I even tried creating a new project with just the tab control and it still does the same thing. I can, tho, move the button using the keyboard arrows!

I'm using VS2010 V10.0.30319.1 RTMREL on WinXP SP3.

View 1 Replies

C# - Detecting The Form Move Event From Within A Child Control?

Jul 8, 2010

I am creating a user control where when a user clicks a button a popup window will show up with information. The popup window is driven by a toolStripDropDown so when it shows up it does 2 things

Does not move the other controls on the form around but displays over them That it can show the details outside the bounds of the user control itself without having to reserve the space ahead of time

Here is some code

Public Class Popup
Private treeViewHost As ToolStripControlHost
Private Shadows dropDown As ToolStripDropDown

[Code].....

Now my issue is as the form moves or resizes the Tooldropdown does not move relative. I understand that. When I try to capture the move event of the user control that event does not fire when the entire form moves. There has to be something I can capture because the controls in the container of the form move relative, what drives that? I tried wndproc but nothing fires during form move unless the form is repainted.

View 4 Replies

VS 2008 - MDI Child - Controls Move Up The Form At Runtime

Jul 29, 2009

I have an MDI application which uses fixed sized forms. I've started to change the forms to sizeable and anchored the controls so they move when the form is resized. If the child form has a menu this jumps onto the parent menu (as it always has done) but all the controls move up the form at runtime and leave a space at the bottom of the child. If I change the form in design mode to cut through the bottom controls i.e. so the form doesn't appear tall enough, it corrects itself at runtime. Is there another workaround as it looks misleading in the designer.

View 3 Replies

Controlling The Minimized Size Of A MDI Child Form

Nov 21, 2009

Is there a way to control the size of a minimized MDI form. When I minimize a child form, it apprears at the bottom with the form buttons (minimize, restore and maximize) and just about 2 or 3 characters of the Title Text. I would like to have more of the title text showing so the user can figure out what window he wants to restore if he has a couple of them minimized. If not that, is there a way to have a "tooltip" popup when I move the mouse over the minimized form.

View 2 Replies

Create The Relationship So That When Move Thruogh Master The Child Have Corresponding Records?

May 21, 2009

I created a dataset.xsd and it contains two table adapters and these table adapters use stored procedure for select.in my vb form, i get value in text box and then fill table using tableadapter and pass parameter to sp. Till this point everything is working fine. Now these tables have relations and i want to create relationship and show the data from child table on basis of master table. How i can do it?

Example

Me.MasterTableAdapter.Fill(Me.dataset1.spMaster, 1) --1 is parameter which is passed to sp
Me. ChildTableAdapter.Fill(Me.dataset1.spChild,1) --same parameter is passed to child table.

Now i have the records in spMaster and spChild. how i create the relationship so that when i move thru Master the child have corresponding records?

View 1 Replies

Limit Space Child Form Can Move Inside Main One?

Mar 25, 2009

I want that the child form's moving space inside the main form would be limited so it wouldn't go over the borders like in the picture.[code]...

View 2 Replies

Move Or Change Size Of A Button At Runtime In Program?

Dec 22, 2011

I am using vb.net,is it possible to change the size or place of a button at run time.I meant we can click and drag the button to increase the size or move?

View 2 Replies

Detect And Set The Form Size In The Child And MDIParent Forms?

Feb 5, 2012

Anybody know a way to detect and set the form size in the child and MDIParent forms?

I'm having all kinds of problems from scroll bars popping up, to can't get the form to fill the parent. Pretty sure I have tried every possible combination in the forms properties 10 times.

I'm really getting tired of beating myself against this. Anybody seen a good tutorial on the finer points of MDIparent / MDI Child page size, etc.

View 1 Replies

Child Window On Top?

May 19, 2009

(vbnet 2008, windows forms)I have a main form (not MDI) with a menu that will open another form as a window on top (I have already set the TopMost property to true). My problem is that it will set this window on top of everything that I open (any program). How can I set this window to be on top of just the main form? I guess I have to declare the main window as its parent, I tried the code below but it didn't work...

Code:
Private Sub FilterToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles FilterToolStripMenuItem.Click
Dim frm As New frmFilter

[code]......

View 2 Replies

VS2008 Move To W7 - Compiler Producing Different Size Install File?

Nov 29, 2009

I'm currently moving over to W7 from Vista I've moved my source over (amazingly hassle free), but the Build option on my installer in my solution produces a different size (200K+) setup.exe file.

Initial question are:

1) Is there a log file I can compare betwen the two builds (V7 -v- Vista)

2) I thought that any compiler settings would 'follow the solution' Is this so?

View 3 Replies

Move Image On Window WPF

Aug 18, 2010

[code]how can i change position of this image on Code Behind?

View 2 Replies

Move Window Using An Image Box?

Aug 15, 2010

I'm trying to make a custom GUI and I made the title bar on MS paint and have it all setup all i need it the code snippit to make the window move when the image is draged to different places.

View 3 Replies

How To Get The Child Window Handler

Mar 17, 2008

In my example, Internet Explorer is the parent window. I just want to get the plain text from its child window. For that i need to get the handle of child window.

View 12 Replies

SendKeys To Child Window

Jan 3, 2012

I have a small and irritating problem.

I used the following code to captute and set a 3rd party application as a child of my VB application:

<CodeStart>
If
ofd.ShowDialog And

[Code]....

View 5 Replies

Change The Size Of Child Form And Add Controls From Parent In A Showdialog Mode?

Mar 17, 2012

I have an outlook application, whenever the user receive a new mail I show him a form and some controls

The user needs to insert information and close the form. Sometimes the user is not near his machine so whenever there is a new mail I am adding new controls and modify the child size.

It has been successful using the Form.show() method but not in showdialog() i cant add controls and change the form size can someone please help on the subject?

[Code]...

View 8 Replies

VS 2008 Resize Of Parent Form Keeps Relative Size/Loc Of Child Forms?

Sep 17, 2010

I want a set of child forms to keep their relative sizes and locations to their parent form when parent form is resized. So if one child form is opened and covers the lower right quadrant.. it will remain a quadrant for whatever resize is done on parent form.

View 3 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved