12-10-2008 03:53 AM
Clean Up Diagram is very useful tool, specially for small block diagrams. But my experience with larger diagrams is not very good. If case structure with many cases is used (or event structure with many events) then the final result of cleaning is a very large diagram with a lot of unused space.
My wish: a "Clean Up Diagram" tool which cleans selected items only. Only one case in the case structure, for example. It should work like [Edit - Create SubVI] menu command.
Best regards to everybody,
Ljubo.
12-10-2008 07:13 AM
Ljubo,
your feedback is valuable. But as a "fan of good style" i have to confess that using Clean Up Diagram is something you should not depend on. You should design and implement your code in a way that using that function is not necessary!
Nevertheless, there are of course situation where this tool comes handy (e.g. getting improper code from other developers....). So an example for a current workaround:
- Create a SubVI from the segment youwant to clean up
- Use the Clean Up Diagram function on the SubVI
- Either leave the SubVI in the Case (don't forget to clean up the icon!) or recopy the content of the SubVI to the case (not perfect since you have to reconnect the in/ouputs)
hope this helps,
Norbert
12-10-2008 09:55 AM
Norbert,
I tried Clean Up Diagram tool a few times and then I realised it is not necessary to take care about design in the first phase of development. I can simply "throw" icons on the block diagram and connect them without using tools for aligning and distributing objects. But, ..., you always have to have in mind the final view. To ilustrate this I attached three screen shots:
1. development phase: the first phase of development
2. cleaned up, perfect planning: wires are not crossed; just a click on the Clean Up Diagram tool was enough to come to this diagram from the diagram on the first picture.
3. cleaned up, bad planning: wires are crossed
So, I think we agree that a tool is good if you know how and when to use it.
Best regards,
Ljubo.
12-23-2008 10:06 AM
I agree on the usefulness of this tool in regards to small block diagrams. When I'm working on a small subVI, the cleanup is invaluable.
I really wish there was a similar tool for the front panel for subVI's that would arrange the controls and indicators by their locations on the connector pane. This would considerably speed development of minor subVI's that don't need much in the way of front panel prettiness.
One problem I have discovered, though, is that if the diagram is sufficiently large (I think that's the trigger anyway, though it might have to do with controls outside of a while loop), the cleanup button does nothing but play the windows "default beep" sound.
I also second a call for being able to cleanup a subsection of code. That would be a great add-on to this new feature.
12-23-2008 12:08 PM
Mike Webster wrote:
I really wish there was a similar tool for the front panel for subVI's that would arrange the controls and indicators by their locations on the connector pane.
There is. Search the LAVA forums for "subVI fixer". There should be some videos of how to use it.
As for your last point, I think that the diagram clean up tool fails in 8.6 if the resulting diagram is larger than 16K (or maybe 32K) pixels, and I know that NI is aware of it.
12-23-2008 01:08 PM