BLOG main image
전체 (276)
[Computer] (42)
[Programming] (62)
[DBMS] (26)
[Operating System] (21)
[Study English] (8)
[For money] (28)
[Interest] (89)
«   2009/11   »
1 2 3 4 5 6 7
8 9 10 11 12 13 14
15 16 17 18 19 20 21
22 23 24 25 26 27 28
29 30          
77917 Visitors up to today!
Today 14 hit, Yesterday 95 hit
'객체지향'에 해당되는 글 1건
[폭주기관차, 2007/02/20 10:03, [Programming]/Visual Basic]
TextBox를 생성(Text1) 하여 함수로 넘기고 싶을 때
ByRef를 사용하면 된다.

참고 : ByRef = Call by reference, ByVal = Call by value

호출:
Call SelectAllText( Text1 )

함수선언:
Private Function SelectAllText(ByRef Text As TextBox)

With Text
    .SelStart = 0
    .SelLength = Len(.Text)
    .SetFocus
End With

End Function

이 함수는 Text박스 객체를 넘기면 그 Text박스에 적힌 글을 모두 Select해주는 기능을 합니다.
긁어서 사용하시면 됩니다.

Trackback Address :: http://kongmks.cafe24.com/trackback/126
Name
Password
Homepage
Secret
*1