FileSystem.FileWidth(Int32, Int32) 메서드

정의

FileOpen 함수를 사용하여 연 파일에 출력 줄 너비를 지정합니다.

public:
 static void FileWidth(int FileNumber, int RecordWidth);
public static void FileWidth (int FileNumber, int RecordWidth);
static member FileWidth : int * int -> unit
Public Sub FileWidth (FileNumber As Integer, RecordWidth As Integer)

매개 변수

FileNumber
Int32

필수 요소. 유효한 파일 번호입니다.

RecordWidth
Int32

필수 요소. 0~255 사이의 숫자 식으로, 새 줄이 시작되기 전에 줄에 표시되는 문자의 수를 나타냅니다. RecordWidth가 0이면 줄 길이에 제한이 없습니다. RecordWidth의 기본값은 0입니다.

예외

파일 모드가 잘못된 경우

예제

이 예제에서는 함수를 FileWidth 사용하여 파일의 출력 선 너비를 설정합니다.

Dim i As Integer
FileOpen(1, "TESTFILE", OpenMode.Output) ' Open file for output.
FileWidth(1, 5)   ' Set output line width to 5.
For i = 0 To 9   ' Loop 10 times.
    Print(1, Chr(48 + I))   ' Prints five characters per line.
Next
FileClose(1)   ' Close file.

적용 대상

추가 정보