Board index » delphi » Resizing problem with Windows Media Player 9.0
Strom Thurman
Delphi Developer |
Strom Thurman
Delphi Developer |
Resizing problem with Windows Media Player 9.02003-07-24 10:30:49 PM delphi92 The video stays the size of what the component was at design time. The Active X control does not resize with the TOleControl. I have tried importing both the msdxm.ocx and wmp.dll and they each have the same problem. The stretch to fit setting seems to have no affect on Media Player 9.0 but does on other versions of media player. I imported the control into c# and it works fine there to see if the problem is on the Active X side. Does anyone have any suggestions? |
donlelel
Delphi Developer |
2003-07-28 08:39:36 PM
Re:Resizing problem with Windows Media Player 9.0
Hi,
If u search earlier messages , u'll see u have to set parent to nil and then back etc. it is bad that the video restarts , u have to record the position etc. but maybe that is not a concern for u. Don "Joe C. Hecht" <XXXX@XXXXX.COM>writes news:<3f201829$XXXX@XXXXX.COM>... QuoteIf you find the answer elsewhere, please forward to me :) |
donlelel
Delphi Developer |
2003-07-29 05:42:39 AM
Re:Resizing problem with Windows Media Player 9.0
Hello again,
I found another solution - do something like that : MediaPlayer.Visible:=False; MediaPlayer.Width:=MediaPlayer.Width+50; MediaPlayer.Visible:=True; MediaPlayer.SetFocus; Don |
Harald Wagner
Delphi Developer |
2004-02-25 06:35:30 PM
Re:Resizing problem with Windows Media Player 9.0
Hi!
I found a (dirty) solution. In the OnResize-Handler of the Form containing the player I added the following lines: h = GetForegroundWiondow() SetFocus( DesktopWindow ) WMP->Hide WMP->Show SetFocus( WMP ) SetForeGroundWindow( h ) Yes, it looks very silly. But it works... "Joe C. Hecht" <XXXX@XXXXX.COM>schrieb im Newsbeitrag QuoteIf you find the answer elsewhere, please forward to me :) |