programing

vba의 쓰기 문에서 큰따옴표 제거

lastcode 2023. 4. 17. 21:53
반응형

vba의 쓰기 문에서 큰따옴표 제거

이 코드는 LogFilePath에 로그 파일을 쓰고 다음과 같이 출력을 생성합니다.StarRange 및 EndRange는 다른 함수의 값을 채우는 변수입니다.

"Start postion",A1
"End position",B100

---Code-----------------
Sub WriteLogFile()
 Dim FilePath As String

 LogFilePath = WriteTextBox.Text

LogFilePath = LogFilePath & ".log"
Open LogFilePath For Output As #2

Write #2, "Start postion"; StarRange
Write #2, "End position"; EndRange
Close #2

MsgBox FinalFileName

End Sub

궁금한 것은 어떻게 하면 출력에서 큰따옴표를 제거하고 아래와 같이 출력을 낼 수 있을까 하는 것입니다.감사해요.

Start position = A1
End position = B100

Write머신을 통한 파일을 생성하기 위한 특별한 스테이트먼트입니다.이 파일은 나중에 에 의해 사용됩니다.Input.

사용하다Print데이터를 만지작거리지 않도록 합니다.

Print #2, "Start postion = "; StarRange
Print #2, "End position = "; EndRange

언급URL : https://stackoverflow.com/questions/20016895/remove-double-quotation-from-write-statement-in-vba

반응형