Back to Home Visual Graph Home TriSun Software Inc. Home Visual Graph Site Menu Home What is Visual Graph? Screenshots 50 Technical Features Getting Started Abundant Graphic Libraries File Format FAQ Online Demo (IE Only) Common Applications Visual Graph Getting Started Use VG Component in Delphi 6 Use VG Component in VB6 Use Graphic Library Change Element's Shape Customize Property Make Graphic Button Get the Selected Elements Dynamically Create Graph Movable Label Link Point Access Properties Use Line Vertexes Call Windows API Functions Call Visual Graph Functions Callback Control Event in Script Drag Graph in Run Mode Detail Report Make and Use Dialog Box |
Visual Graph Getting Started - Drag Graph in Run ModePlease follow these steps to implement it.1. Create a new file in Visual Graph IDE, and then draw a circle (basic element in library group) in this document. 2. Select current sheet by click the blank, and then click Functions tab at left and double-click Initialize function, write the following script: FStartX = 0 FStartY = 0 3. Select this circle, and then click OnLButtonDown function, write the following script: Sender.Tag = 1 FStartX = X FStartY = Y 4. As above, add the following code to the circle's OnLButtonUp event: Sender.Tag = 0 5. As above, add the following code to the circle's OnMouseMove event: if Sender.Tag = 1 then Sender.MoveBy( X - FStartX, Y - FStartY ) FStartX = X FStartY = Y end if 6. Click Program -> Run, now you can drag this circle by mouse. |
Sitemap |
Legal Notices |
Privacy Policy |
Contact Us |
About Us
Copyright© 2001-2025 TriSun Software Inc. All rights reserved.