Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Try
- rdp.Server = TextBox1.Text
- rdp.UserName = TextBox2.Text
- Dim secured As IMsTscNonScriptable = CType(rdp.GetOcx, IMsTscNonScriptable)
- secured.ClearTextPassword = TextBox3.Text
- rdp.Connect()
- Catch ex As Exception
- MsgBox("ERROR:" & ex.ToString)
- End Try
- End Sub
- Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
- Try
- If rdp.Connected.ToString.Equals("1") Then
- rdp.Disconnect()
- End If
- Catch ex As Exception
- MsgBox("ERROR: " & ex.ToString)
- End Try
- End Sub`
Add Comment
Please, Sign In to add comment