|
|
|
|
<gglDrive variable>.CopyFile (Function) In french: <Variable gglDrive>.CopieFichier
Not available
Copies a file on Google Drive from one directory to another.
oOAuth2Param is OAuth2Parameters
oOAuth2Param.ClientID = "client_id"
oOAuth2Param.ClientSecret = "client_secret"
oOAuth2Param.RedirectionURL = "http://localhost:9000/"
DriveGoogle is gglDrive
DriveGoogle = GglDriveConnect(oOAuth2Param)
tabFicGgl is array of GglFile
tabFicGgl = DriveListFileGgl(gglMonDrive, "/", frRecursive)
FOR EACH MyFile OF tabFicGgl
IF DriveGoogle.CopieFichier(MyFile, "/Sauvegardes/") = False THEN
Error("Impossible de copier le fichier demandé", ErrorInfo())
RETURN
END
END
Syntax
<Result> = <Google Drive>.DriveCopyFile(<Source file> , <Destination directory>)
<Result>: Boolean - if the file was copied successfully,
- False if an error occurs. To get more details on the error, use ErrorInfo with the errMessage constant.
<Google Drive>: gglDrive variable Name of the gglDrive variable that corresponds to the drive to be used. The connection to the drive must have been previously established. Otherwise, the element is not copied. <Source file>: GglFile variable Name of the GglFile variable that corresponds to the Google Drive file to manipulate. <Destination directory>: Character string Path of the directory to which the file will be copied. If this path is not valid, the file will not be copied. Remarks <Destination directory> parameter Examples of valid paths: "/holidays directory/2021/" "\photos" Examples of invalid paths: "directoryA/DirectoryB" "This/Path/Is/invalid" "c:\Users\"
Related Examples:
|
Unit examples (WINDEV): Drive functions
[ + ] This example illustrates the use of Drive functions (Google Drive, Dropbox, OneDrive).
|
|
Unit examples (WINDEV Mobile): Drive functions
[ + ] This example illustrates the use of Drive functions (Google Drive, Dropbox, OneDrive).
|
Business / UI classification: Business Logic
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|