form shape drawing (arc)

Reply

Join Date: Jul 2007
Posts: 4
Reputation: prettyboy is an unknown quantity at this point 
Solved Threads: 0
prettyboy prettyboy is offline Offline
Newbie Poster

form shape drawing (arc)

 
0
  #1
Sep 10th, 2007
dear all,
i'm doing a project which involve shape (arc, circles and rectangles) i'm a newbie on VB6, done the easy shapes but problem on drawing the arc on the form to form a half-moon shape. any help or link on this will be great and appreciated. thnx in advance
Reply With Quote Quick reply to this message  
Join Date: Feb 2007
Posts: 2,093
Reputation: debasisdas will become famous soon enough debasisdas will become famous soon enough 
Solved Threads: 126
debasisdas's Avatar
debasisdas debasisdas is offline Offline
Postaholic

Re: form shape drawing (arc)

 
0
  #2
Sep 11th, 2007
syntax to draw circle, arc etc
-----------------------------------------
OBJECT.CIRCLE [STEP](X,Y),RADIUS,[COLOR,START,END,[ASPECT]]]
--
STEP-IT SPECIFIES THE CENTER OF THE CIRCLE IS RELATIVE TO THE CURRENT COORDINATES GIVEN BY "CURRENTX","CURRENTY"
X,Y-INDICATES THE CENTER COORDINATE OF THE CIRCLE.
RADIUS-INDICATES THE RADIUS.
START,END-WHEN AN ARK OR A PARTIAL CIRCLE IS DRAWN START AND END SPECIFIES THE BEGINNING AND THE END POSITION OF THE ARC.
THE RANGE FOR BOTH IS -2Pi RADIAN TO +2 Pi RADIAN.THE DEFAULT VALUE FOR START IS 0 RADIANS AND THAT FOR END IS 2*Pi RADIANS.
ASPECT-INDICATES THE ASPECT RATIO OF THE CIRCLE.DEFAULT IS 1.0 WHICH YIELDS A PERFECT CIRCLE ON ANY SCREEN.

Hope this solves your problem.
Share your Knowledge.
Reply With Quote Quick reply to this message  
Join Date: Jul 2007
Posts: 4
Reputation: prettyboy is an unknown quantity at this point 
Solved Threads: 0
prettyboy prettyboy is offline Offline
Newbie Poster

Re: form shape drawing (arc)

 
0
  #3
Sep 12th, 2007
hi. thanks for your help. i was able to create the arc but how to make it appear without the click? I want the shape to appear immediately upon loading but it only comes out when i click. I know this is easy stuff for you guys, but as i have mentioned earlier, i'm a newbie, please bear with me. thanks in advance.
Reply With Quote Quick reply to this message  
Join Date: Feb 2007
Posts: 2,093
Reputation: debasisdas will become famous soon enough debasisdas will become famous soon enough 
Solved Threads: 126
debasisdas's Avatar
debasisdas debasisdas is offline Offline
Postaholic

Re: form shape drawing (arc)

 
0
  #4
Sep 13th, 2007
put the code in form paint event

try this
  1. Private Sub Form_Paint()
  2. Me.Circle (ScaleWidth / 2, ScaleHeight / 2), Switch(ScaleWidth >= ScaleHeight, ScaleHeight / 2, ScaleWidth < ScaleHeight, ScaleWidth / 2), vbRed, 0, 3, 0.8
  3. End Sub
Share your Knowledge.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



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

©2003 - 2009 DaniWeb® LLC