VS:Rewrite/ja

From Vectorworks Developer
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

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

Description

指定したファイルのパスに新しいファイルを作成します。

PROCEDURE Rewrite(
fileName :STRING);
def vs.Rewrite(fileName):
    return None

Parameters

fileName STRING ファイルのパス

Example

PROCEDURE Example;
VAR
   fileName :STRING; 
   major, minor, maintenance, platform :INTEGER;
BEGIN
   GetVersion(major, minor, maintenance, platform);
   IF platform = 1 THEN BEGIN
      fileName := '/Example.txt';
   END ELSE BEGIN
      fileName := 'C:\Example.txt';
   END;
   ReWrite(fileName);
   WriteLn('example text');
   Close(fileName);
END;
RUN(Example);

Version

利用可能バージョン: MiniCAD