AYUDA EN LÍNEA
 WINDEVWEBDEV Y WINDEV MOBILE

Este contenido se ha traducido automáticamente.  Haga clic aquí  para ver la versión en inglés.
Ayuda / WLanguage / Funciones WLanguage / Funciones estándar / Funciones de archivos / Procedimiento WLanguage
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReportes y ConsultasCódigo de Usuario (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Código Navegador
WINDEV Mobile
AndroidWidget Android iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Otros
Procedimientos almacenados
WLanguage Procedure llamado por zipAddDirectory para manipular la barra de progreso
WLanguage Procedure ("Callback") utilizado por zipAddDirectory para gestionar el progreso de los ficheros que se añaden al archivo.
Ejemplo
// -- Global declarations of the window
GLOBAL
ArchiveName is string = "MyArchive"
// -- Click on BTN_AddDirectory
// Initialize the variables
DirectoryName is string
CreationErrorCode is int
AdditionErrorCode is int
 
// Create an archive
CreationErrorCode = zipCreate(ArchiveName, "C:\MyDirectory\MyArchives\PdfArchive.wdz")
 
// Display an error message if the archive was not created
IF CreationErrorCode = 0 THEN
// Select the directory
DirectoryName = fSelectDir("", "", "Directory to add")
// Adds all the files found in the selected directory into the archive
ErrorCodeAddition = zipAddDirectory(ArchiveName, DirectoryName, False, zipDirectory, ...
zipAddDirectoryProgressBar_Callback)
// Display an error message if the file was not added
IF AdditionErrorCode <> 0 THEN
Error(zipMsgError(AdditionErrorCode))
END
ELSE
Error(zipMsgError(CreationErrorCode))
END
// This procedure is used to manage the progress bar.
INTERNAL PROCEDURE zipAddDirectoryProgressBar_Callback(CurrentFile is string,
OverallProgress is int, FileProgress is int)
IF OverallProgress < 100 THEN
ProgressBar(OverallProgress, 100, CurrentFile)
// Refresh the window
Multitask(-1)
 
ELSE
ProgressBar()
END
END
Sintaxis
zipAddDirectory_ProgressBarCallBack(<Current file> , <Overall progress percentage> , <File progress percentage>)
<Current file>: Cadena de caracteres
Nombre del archivo que se está procesando.
<Overall progress percentage>: Integro
Porcentaje de progreso de los ficheros añadidos al archivo.
<File progress percentage>: Integro
Porcentaje de progreso del fichero que se está añadiendo al archivo.
Observaciones
Si se utiliza un archivo 7z de , sólo se especifica <Porcentaje de progreso general>. <El porcentaje de progreso del archivo tendrá el mismo valor.
Clasificación Lógica de negocio / UI: Código neutro
Componente: wd290java zip.dll
Versión mínima requerida
  • Versión 26
Esta página también está disponible para…
Comentarios
Haga clic en [Agregar] para publicar un comentario

Última modificación: 27/05/2022

Señalar un error o enviar una sugerencia | Ayuda local