|
|
|
|
|
- Properties specific to GglFile variables
- Possible export formats for Google Docs files (mimeTypeGglDocs constant)
- Possible export formats for Google Docs files (mimeTypeGglDocs constant)
- Possible export formats for Google Slides files (mimeTypeGglSlides constant)
- Possible export formats for Google Drawings files (mimeTypeGglDrawings constant)
- Possible export formats for Apps Scripts files (mimeTypeGglAppsScript constant)
- Functions that use the GglFile type
GglFile (Variable type) In french: FichierGgl
The GglFile type is used to get all the characteristics of a file used in one of the Google Docs Editors (Docs, Sheets, etc.). These files can only be stored and edited on Google Drive. This drive is handled using a variable of type gglDrive. NOTE: Variables of type GglFile can only be created and initialized with DriveListFileGgl. Note: For more details on the declaration of this type of variable and the use of WLanguage properties, see Declaring a variable. oOAuth2Param is OAuth2Parameters
oOAuth2Param.ClientID = "client_id"
oOAuth2Param.ClientSecret = "client_secret"
oOAuth2Param.RedirectionURL = "http://localhost:9000/"
gglMyDrive is gglDrive
gglMyDrive = GglDriveConnect(oOAuth2Param)
arrGglFile is array of GglFile
arrGglFile = DriveListFileGgl(gglMyDrive, "/", frRecursive)
FOR EACH Queue OF arrGglFile
SWITCH Queue.MimeType
CASE mimeTypeGglDocs: Queue.ExportMimeType = mimeTypeDOCX
CASE mimeTypeGglSheets: Queue.ExportMimeType = mimeTypeXLSX
OTHER CASE: Queue.ExportMimeType = mimeTypePDF
END
let ResDownload = DriveDownloadGglFile(gglMyDrive, arrGglFile[1], "c:\MyDocuments")
IF ErrorOccurred THEN
Trace ("An error has occurred")
RETURN
END
END
Properties Properties specific to GglFile variables The following properties can be used to manipulate Google files: | | | Property name | Type used | Effect |
---|
Path | Character string | Path to the file on the drive. This property is read-only. | ExportMimeType | Character String constant | Mime type corresponding to the different export possibilities according to the document type (see Remarks). | New in version 2025LastModificationDate | DateTime | Date and time the file was last modified. This property is only specified if the fdFullInformation constant has been used with the DriveListFileGgl function. This property is read-only. | New in version 2025Length | Integer | File size in bytes. This property is only specified if the fdFullInformation constant has been used with the DriveListFileGgl function. This property is read-only. | MimeType | Character String constant | Mime type of the Google file: - mimeTypeGglAppsScript: Apps Script.
- mimeTypeGglDrawings: Google Drawings.
- mimeTypeGglDocs: Google Docs.
- mimeTypeGglSheets: Google Sheets.
- mimeTypeGglSlides: Google Slides.
This property is read-only. | Name | Character string | Name of the file on the drive. This property is read-only. |
Remarks Possible export formats for Google Docs files (mimeTypeGglDocs constant) | | | Exported file type | Constant (MimeType) | Exported file extension |
---|
Microsoft Word | mimeTypeDOCX | .docx | OpenDocument | mimeTypeODT | .odt | Rich text | mimeTypeRichText | RTF | PDF | mimeTypePDF | .pdf | Plain text | mimeTypeText | .txt | Web page (HTML) | mimeTypeZIP | .zip |
Possible export formats for Google Docs files (mimeTypeGglDocs constant) | | | Exported file type | Constant (MimeType) | Exported file extension |
---|
Microsoft Excel | mimeTypeXLSX | .xlsx | OpenDocument | mimeTypeODS | .ods | PDF | mimeTypePDF | .pdf | Web page (HTML) | mimeTypeZIP | .zip | Comma-separated values (first sheet only) | mimeTypeCSV | .csv | Tab-separated values (first sheet only) | mimeTypeTSV | .tsv |
Possible export formats for Google Slides files (mimeTypeGglSlides constant) | | | Exported file type | Constant (MimeType) | Exported file extension |
---|
Microsoft PowerPoint | mimeTypePPTX | .pptx | ODP | mimeTypeODP | .odp | PDF | mimeTypePDF | .pdf | Plain text | mimeTypeText | .txt | JPEG (first slide only) | mimeTypeJPG | .jpg | PNG (first slide only) | mimeTypePNG | .png | Scalable Vector Graphics (first slide only) | mimeTypeSVG | .svg |
Possible export formats for Google Drawings files (mimeTypeGglDrawings constant) | | | Exported file type | Constant (MimeType) | Exported file extension |
---|
PDF | mimeTypePDF | .pdf | JPEG | mimeTypeJPEG | .jpg | PNG | mimeTypePNG | .png | Scalable Vector Graphics | mimeTypeSVG | .svg |
Possible export formats for Apps Scripts files (mimeTypeGglAppsScript constant) | | | Exported file type | Constant (MimeType) | Exported file extension |
---|
Json | mimeTypeJSON | .json |
Functions that use the GglFile type The following functions use GglFile variables:
| | DriveCopyFile | Copies a single file on a remote drive to another directory on same drive. | DriveDeleteFile | Deletes a file from a remote drive. | DriveDownloadGglFile | Downloads a Google Docs Editors file from Google Drive in a given compatible format. | DriveListFileGgl | Lists Google Docs Editors files (Docs, Sheets, etc.) present on Google Drive. | DriveMoveFile | Moves a file on a remote drive from one directory to another. | DriveRename | Renames a file or directory on a remote drive. |
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|