VS:GetFileInfo/ja

From Vectorworks Developer
Jump to: navigation, search

.VectorScript|VectorScript ..VS:Function Reference|Function Reference ..VS:Function_Reference_Appendix|Appendix


Description

ファイルの属性を返します。
PROCEDURE GetFileInfo(
filename  :STRING;
VAR fullReadPath  :STRING;
VAR fullWritePath  :STRING;
VAR readFileExists  :BOOLEAN;
VAR writeFileExists  :BOOLEAN;
VAR locked  :BOOLEAN;
VAR hasReadPermission  :BOOLEAN;
VAR hasWritePermission  :BOOLEAN;
VAR hasFolderPermission  :BOOLEAN);
def vs.GetFileInfo(filename):
    return (fullReadPath, fullWritePath, readFileExists, writeFileExists, locked, hasReadPermission, hasWritePermission, hasFolderPermission)

Parameters

filename STRING
fullReadPath STRING
fullWritePath STRING
readFileExists BOOLEAN
writeFileExists BOOLEAN
locked BOOLEAN
hasReadPermission BOOLEAN
hasWritePermission BOOLEAN
hasFolderPermission BOOLEAN

Example

PROCEDURE Example;
VAR
   fileName :STRING;
   fullReadPath, fullWritePath :STRING;
   readFileExists, writeFileExists, locked, hasReadPermission, hasWritePermission, hasFolderPermission :BOOLEAN;
BEGIN
   fileName := Concat(GetFolderPath(1), 'ADINIT.DAT');
   GetFileInfo(fileName, fullReadPath, fullWritePath, readFileExists, writeFileExists, locked, hasReadPermission, hasWritePermission, hasFolderPermission);
   ReWrite('Output.txt');
   WriteLn('fileName:            ', fileName);
   WriteLn('fullReadPath:        ', fullReadPath);
   WriteLn('fullWritePath:       ', fullWritePath);
   WriteLn('readFileExists:      ', readFileExists);
   WriteLn('writeFileExists:     ', writeFileExists);
   WriteLn('locked:              ', locked);
   WriteLn('hasReadPermission:   ', hasReadPermission);
   WriteLn('hasWritePermission:  ', hasWritePermission);
   WriteLn('hasFolderPermission: ', hasFolderPermission);
   Close('Output.txt');
END;
RUN(Example);

Version

利用可能バージョン: VectorWorks12.0
Personal tools
NamespacesFFFF

Variants
Actions
Advanced Search
See Also
Navigation
Toolbox
In other languages