FixedLengthString.Value 속성
정의
중요
일부 정보는 릴리스되기 전에 상당 부분 수정될 수 있는 시험판 제품과 관련이 있습니다. Microsoft는 여기에 제공된 정보에 대해 어떠한 명시적이거나 묵시적인 보증도 하지 않습니다.
의 내용을 FixedLengthString가져오거나 설정합니다.
public:
property System::String ^ Value { System::String ^ get(); void set(System::String ^ value); };
public string Value { get; set; }
member this.Value : string with get, set
Public Property Value As String
속성 값
값을 포함하는 A String 입니다.
예제
다음 예제에서는 선언 하 고 사용 하는 방법을 보여 줍니다 FixedLengthString.
Private Sub DemoFixedLengthString()
' Declare a string that has a length of 7 characters and assign the
' initial string. The additional 5 positions will be padded with
' spaces.
Dim fixedString As New FixedLengthString(7, "He")
' Display the string in a message box.
MsgBox(fixedString.ToString)
' Assign a new value to the string.
fixedString.Value = "Hello World"
' Display again. Note that only the first 7 characters are shown.
MsgBox(fixedString.ToString)
End Sub
설명
이 클래스를 FixedLengthString 사용하여 Visual Basic 6.0 문자열의 동작을 에뮬레이트할 수 있으며, 이를 통해 고정 길이로 문자열을 선언할 수 있습니다. A FixedLengthString 를 변환할 수 없습니다. String속성을 참조 Value 하거나 메서드를 ToString 호출하여 형식을 변환해야 합니다.
메모
네임스페이 Microsoft.VisualBasic.Compatibility.VB6 스의 함수 및 개체는 Visual Basic 6.0에서 Visual Basic 2008로 업그레이드하기 위한 도구에서 사용할 수 있도록 제공됩니다. 대부분의 경우 이러한 함수와 개체는 .NET Framework의 다른 네임스페이스에서 찾을 수 있는 기능을 복제합니다. Visual Basic 6.0 코드 모델이 .NET Framework 구현과 크게 다른 경우에만 필요합니다.