|
User Name
|
Padrone |
|
Unique Hits
|
1,633 |
|
Real Name
|
- - - |
|
Location
|
United Kingdom South Yorkshire |
|
Occupation
|
- - - |
|
Gender
|
Male |
|
Age
|
19 Years Old |
|
WebSite
|
- - - |
|
|
VB - Simple Pelican Crossing
Programming
|
Simple Pelican Crossing
Specification;
Rename the form frmPelican in Solution Explorer. Label the form Lights.
Add a picture box. Set MinimumSize to 50, 50 and MaximumSize to 50, 50.
Set the Border style to Fixed3D.
Copy it and paste it twice.
Label them from the top; picRed, picAmber and picGreen.
Add a text box. Label it txtWait. Set MiniumSize to 50, 30 and MaximumSize to 50, 30. Set the Text to WAIT and the font MS Sans 10 point, Bold.
Add a button and label it cmdCross. Set MiniumSize to 50, 25 and MaxiumSize to 50, 25.
Add a timer. Label it tmrTime. Set the interval to 1000 (= 1 Second) and Enabled to False.
This is the code.
Operation;
Code
'Double click the form to access the Private Sub frmPelican_Load event.
Private Sub frmPelican_Load
'Click above it to add to Public Class frmPelican section
Public Class frmPelican
'Add a global integer variable intTime and a Boolean variable binPressed
'Global variables to hold the time in sec... View In Full
 |
0 Comments |
5.00 out of 10 |
|
|
VB - Clock
Programming
|
Clock
Objective;
Create a form that show's the current Time.
Specification;
Set up a form as a clock with a textbox.
Rename the Form1.vb to frmClock. Set the title to "Clock", the BackColor to system Desktop, the ForeColor system ForeColor and the Font to Arial 16.
Set the textbox name to txtTime.
Add a timer and rename it to tmrTimer, set its interval to 1000, and Enabled to "True".
Double click the tmrTimer_Tick code.
Enter this code.
Operation;
Code
Dim timTime As Date
timTime = My.Computer.Clock.GmtTime
Me.txtTime.Text = timTimer.Hour & ":" & timTime.Minute & ":" & timTime.Second
I hoped this helped you in learning VB,
There will be more out. Check my profile for more post's. View In Full
 |
0 Comments |
1.00 out of 10 |
|
|
VB - Hi Bye
Programming
|
Hi Bye
Objective;
Create a form that appears slowly with the message "Hello" until fully opaque. On clicking a button, the message changes to "Bye" and then fades out. When it is invisible it will be closing the form and program.
Specification;
Rename the Form1.vb to frmHiBye. Set the title to "Hi Bye", the BackColor to web Red, the ForeColor to web Gold and the Font to BauHaus 10.
Set the Opacity to 0%.
Set the textbox name to "txtHi" and its text property to "Hello".
Set the button name to cmdBye and its text property to "Bye".
Add a timer and rename it tmrTimer, Set its interval to 200, and Enabled to "True".
Double click the form to add the form code, double click the button to enter cmdBye_Click code and double click the timer to enter the tmrTimer_Tick code.
This is the code.
Operation;
Code
Public Class frmHiBye
Public dblTime As Double
Public binClosing As Boolean
Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.Ev... View In Full
 |
0 Comments |
5.00 out of 10 |
|
|
| Please login to post comments. |
|
 |
|
United Kingdom, South Yorkshire |
|
|
Padrone has 0 fans
become a fan |
|
 |
|
|
 |
|