C# Controls

C#/문법 및 기능 2015. 9. 18. 15:29
728x90

VB.NET 과 C# 의 표현이 어떻게 다른지 알 수 있는 거 같아서 적어둔다.

'// Visual Basic
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
   Dim MyText As New TextBox()
   MyText.Location = New Point(25, 25)
   Me.Controls.Add(MyText)
End Sub

// C# private void button1_Click(object sender, System.EventArgs e) { TextBox myText = new TextBox(); myText.Location = new Point(25,25); this.Controls.Add (myText); }


블로그 이미지

Link2Me

,