I need a drag drop application in vb6 or vb.net that will allow a user to create and simulate an electrical diagram.
(Images attached show how the system should work)
The program needs to have 2 states, design time and run time.
I need it to start in design mode basic with the following components available: A power supply, a Switch (horizontal and vertical) and a Lamp.
The user can drag as many of these on screen as they want and then user a wire tool to connect them to each other. (Images for each are attached)
The wire must be a line which can only be horizontal or vertical.
The main aim is to make sure each component knows which wire it is connected to and each wire knows what component is is connected to.
If you can get the design stage completed I can take care of run time. However if you want a go.
In run time the program must track power flowing through the diagram. For example on will be green and off is black. When the power supply is turned on it changes to green and so does wires connected to it. If a connected switch is in the open state it will remain black as will the wire connected on the other side. Once the switch is closed (by clicking on it) it will change to a closed state and turn green and so will the wire connected to it. This will continue until the switch connected to the lamp is closed and the lamp turns on. If the power supply is turned off, all switches will open and components will turn black.
This is further illustrated in the attached images.
Power in the diagram will be displayed by the component changing colour. Please see the attached pictures as a further example.