ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

This content has been translated automatically.  Click here  to view the French version.
Help / WLanguage / WLanguage functions / Standard functions / Windows functions / MCI functions
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
MCIWindowSize (Function)
In french: MCITailleFenêtre
Changes the size and position of the display window of a media file previously opened (MCIOpen).
Caution: During the opening, the name of container window must have been specified beforehand.
Example
MCIOpen("Film.avi", "MyFilm", MciStyleChild, IMG_Image)
...
MCIWindowSize("MyFilm", MciModeStretched)
 
MCIPlay("MyFilm")
...
MCIClose("MyFilm")
Syntax

Resizing the display window Hide the details

<Result> = MCIWindowSize(<Media file or alias> , <X Position> , <Y Position> , <Width> , <Height> [, <Parameters> [, <Name of the message window>]])
<Result>: Boolean
  • True if the modification was performed,
  • False otherwise. To get the error number, use MCIErr.
    To get more details on the error, use MCIMsgErr or ErrorInfo with the errMessage constant.
    The status report of the command is returned by MCIRetrieve.
<Media file or alias>: Character string
Name of the media file to be used (AVI, MP3, etc.) or alias defined when opening the file (MCIOpen).
<X Position>: Integer
New horizontal position (X-coordinate) of the display window.
<Y Position>: Integer
New vertical position (Y-coordinate) of the display window.
<Width>: Integer
New width of display window.
<Height>: Integer
New height of display window.
<Parameters>: Optional character string
Additional parameters if necessary. These parameters can be known by checking the documentation of Windows MCI function named "open".
The MciWait constant can be added to this string. This constant is used to indicate that the program must wait for the end of the MCI command to run the rest of application.
<Name of the message window>: Optional character string
Name of the window used to intercept and manage the different messages sent by MMSYSTEM.DLL. These messages are in MM_xxxxxx format and can be retrieved with Event. You can for example get messages regarding the management of CD ROM or Joystick.

Modifying the display mode Hide the details

<Result> = MCIWindowSize(<Media file or alias> , <Display mode> [, <Parameters> [, <Name of the message window>]])
<Result>: Character string
Position in the file. This position is expressed in the format specified by MCIPositionFormat.
<Media file or alias>: Character string
Name of the media file to be used (AVI, MP3, etc.) or alias defined when opening the file (MCIOpen).
<Display mode>: Constant
Mode for displaying the file in the window:
MciModeCenteredImage centered in the window
MciModeHomotheticCentered
(Default value)
Image proportionally stretched
MciModeNormalDisplay at 100%
MciModeStretchedImage stretched to occupy the entire surface
<Parameters>: Optional character string
Additional parameters if necessary. These parameters can be known by checking the documentation of Windows MCI function named "open".
The MciWait constant can be added to this string. This constant is used to indicate that the program must wait for the end of the MCI command to run the rest of application.
<Name of the message window>: Optional character string
Name of the window used to intercept and manage the different messages sent by MMSYSTEM.DLL. These messages are in MM_xxxxxx format and can be retrieved with Event. You can for example get messages regarding the management of CD ROM or Joystick.
Component: wd290std.dll
See also
Minimum version required
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 06/02/2022

Send a report | Local help