ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / WLanguage / WLanguage functions / Standard functions / Windows functions / CD and DVD burning functions
  • Procedure used to manage the different events that occur
  • Sessions and tracks
  • Compilation
  • Burned audio CD/DVD
  • Required configuration
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
Burns the files found in the compilation onto the CD or DVD.
During the burn process, BurnerSave regularly calls a specific WLanguage procedure. This procedure is used to manage the different events that occur during the burn process.
Remarks:
  • After BurnerSave is called, the current compilation is automatically deleted.
  • This function is not locking. To find out if the burning is complete, use the WLanguage procedure regularly called by BurnerSave.
// Actual CD burning
// The burner door will be automatically opened at the end of burn process
ResBurn is boolean
ResBurn = BurnerSave(burnerAutoEject, ProcBurnCD)
// To view the entire example, click the "Example" link
Syntax
<Result> = BurnerSave(<Burn options> [, <WLanguage procedure> [, <Pointer>]])
<Result>: Boolean
  • True if the files are currently burnt onto the CD or DVD,
  • False otherwise. To get more details on the error, use ErrorInfo.
    To find out if the burning is complete, test the event encountered in the <Procedure name> procedure.
Remark: A CD or a DVD must be found in the burner. This CD/DVD must contain enough space to burn a new session.
<Burn options>: Integer constant (or combination of constants)
Option for burning files on the CD or DVD:
burnerAutoEjectOpens the burner door at the end of burn process.
burnerFinalizeFinalizes the media: no other write operation can be performed on the media.
Remark: Nevertheless, the rewritable medias can be erased and re-used.
burnerNoEjectDoes not open the burner door at the end of burn process.
burnerSimulateSimulates the burning of CD or DVD. All the steps of the burn process are performed except for the actual burning of files on the CD/DVD.

By default, the files are actually burned on the CD/DVD (no simulation) and the burner door is not opened at the end of burn process.
<WLanguage procedure>: Optional procedure name
Name of the WLanguage procedure ("callback") regularly called during the burn process. This procedure is used to manage the different events that occur.
This procedure has the following format:
PROCEDURE <Procedure name>(<Event encountered>, <Event message>,
<Procedure pointer>, <Parameter 1>, <Parameter 2>)
The parameters of this procedure are optional.
There is no need to pass parameters to this procedure. Indeed, these parameters are automatically filled whenever a file is processed.
<Pointer>: Optional integer
Pointer passed to <Procedure name>.
Remarks

Procedure used to manage the different events that occur

BurnerSave regularly calls the <Procedure name> procedure. This procedure is used to manage the different events that occur during the burn process. This procedure is a local or global procedure.
This procedure must be declared as follows:
PROCEDURE <Procedure name>(<Event encountered>, <Event message>,
<Procedure pointer>, <Parameter 1>, <Parameter 2>)
  • <Event encountered> is a constant indicating the type of event.
  • <Event message> is a character string containing the message of the event encountered.
  • <Procedure pointer> is an integer whose value is the one passed to the <Pointer> parameter of BurnerSave. If <Pointer> is not specified, <Pointer> is set to 0.
  • <Parameter 1> and <Parameter 2> are integers containing a value specific to the event that occurred.
The different values are as follows:
Event<Event encountered><Event message><Parameter 1><Parameter 2>
Cancel the burn processburnerNotificationCancel""00
Error detectedburnerNotificationErrorError messageCode of error that occurred0
Close the CD/DVDburnerNotificationCloseCD""Duration (in seconds) for closing the CD/DVD0
Burn process completedburnerNotificationEndBurningError message if <Parameter 1> is different from 0, empty string ("") otherwiseReturn code, 0 if no error0
Burn a blockburnerNotificationBurnBlock""Rank of the current blockTotal number of blocks to burn
Burn a trackburnerNotificationBurnTrack""Rank of the current trackTotal number of tracks to burn
Prepare to burnburnerNotificationPrepareBurning""Duration (in seconds) for preparing to burn0
Other event Event messageRank of the current stepTotal number of steps to perform

To get the value of <Procedure pointer>, its value must be assigned to the value of <Pointer> in the procedure with Transfer.
Remark: The parameters of this procedure are optional: you have the ability to specify the event and the message for example.

Sessions and tracks

The CDs/DVDs are divided into sessions and tracks. A session corresponds to all the files burned at the same time during a single operation. A track corresponds to a file. A session can contain one or more tracks.
Each new burn operation on the same CD/DVD generates a new session on the CD/DVD.
Remark: For an audio CD/DVD, some CD/DVD readers can only read the tracks of the first session.

Compilation

A compilation corresponds to the set of files that must be burned on a CD or DVD. This compilation will be taken into account next time BurnerSave is called.
A compilation is automatically created during the first call to BurnerAddFile or to BurnerAddDirectory. A single compilation can be created at a time.
A compilation is automatically deleted:
  • when changing the type of CD/DVD to burn (BurnerMediaType).
  • when selecting the default burner (BurnerSelect).
  • after the call to BurnerSave (only if the burn process was started, <Result> is set to True).
  • when canceling the burn process (BurnerCancel).
  • when closing the current WINDEV application or WEBDEV site.

Burned audio CD/DVD

You cannot burn a compilation on an audio CD/DVD that is already burned.

Required configuration

WEBDEV - Server code The CDs and the DVDs will be burned on the Web server. To burn CDs or DVDs, the server must be running Windows XP or later. To burn CDs in Windows 2003 Server, the IMAPI burn service (named "IMAPI CD-burning COM service") must be enabled. To burn DVDs in Windows 2003 Server, you also have to install the KB932716 update.
Component: wd290grv.dll
Minimum version required
  • Version 10
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 05/26/2022

Send a report | Local help