find the error please...

Please support our VB.NET advertiser: Intel Parallel Studio Home
Thread Solved

Join Date: Oct 2007
Posts: 8
Reputation: WhitePunk is an unknown quantity at this point 
Solved Threads: 0
WhitePunk WhitePunk is offline Offline
Newbie Poster

find the error please...

 
0
  #1
Oct 3rd, 2007
i have a code of a projectile but...
can these code be shorten or not???
i need new version of this and some times if i played this one some error was done
hope you could help me to fing the error


Option Explicit
Dim Angle, Theta, y, x, t, Vo As Single
Const pi = 3.141592654

Private Sub cmdClear_Click()
txtSpeed.Text = ""
txtAngle.Text = ""
End Sub

Private Sub cmdGo_Click()
giatayngatimer.Enabled = True
Vo = Val(txtSpeed.Text)
Theta = pi * Val(txtAngle.Text) / 180
t = 0

End Sub

Private Sub cmdStop_Click()
giatayngatimer.Enabled = False
End Sub

Private Sub Form_Load()
giatayngatimer.Enabled = False
Scale (-45, 1000)-(1000, -1000)
Line (1000, -45)-(-1000, 1000), , BF
End Sub

Private Sub giatayngatimer_Timer()
y = Vo * Sin(Theta) * t - (4.9) * (t ^ 2)
x = Vo * Cos(Theta) * t
t = t + 1
shapeCircle.Top = Fix(y)
shapeCircle.Left = Fix(x)
End Sub



thanx a lot!!! god bless you!!!! and more powers!!!
Reply With Quote Quick reply to this message  
Join Date: Jun 2007
Posts: 82
Reputation: preetham.saroja is an unknown quantity at this point 
Solved Threads: 1
preetham.saroja's Avatar
preetham.saroja preetham.saroja is offline Offline
Junior Poster in Training

Re: find the error please...

 
0
  #2
Oct 12th, 2007
u mean,it has to b written in vb.net or entire procedure to be reduced!!!
Reply With Quote Quick reply to this message  
Reply

This thread has been marked solved.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the VB.NET Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC