Sub auto()
txtProductCode.Text = "P-" & GetUniqueKey(4)
End Sub
End Sub
Private Sub SomeTextBox_KeyPress(sender As Object, e As KeyPressEventArgs) Handles
SomeTextBox.KeyPress
If Asc(e.KeyChar) = 13 Then
MessageBox.Show("Enter pressed!")
e.Handled = True
End If
End Sub
and then you would handle the event keydown on the textbox. One of the answer was
on the right track but missed setting the e.IsInputKey.
End If
End Sub
Add the following line of code to your Page_Load event
Page.RegisterHiddenField("__EVENTTARGET", "YourButtonName")
PictureBox1.Image = Image.FromFile("d:\testImage.jpg")
PictureBox1.SizeMode = PictureBoxSizeMode.StretchImage
End Sub
End Class
NOTE: If you want the MDI parent to auto-size the child form you can code
like this.
form.MdiParent = Me
form.Dock = DockStyle.Fill
form.Show()
End Class
https://www.youtube.com/watch?v=LfHSZ7vLwyU&feature=youtu.be create
delee