Go to Post There is something to be learned (sometimes hard to find) from everyone you meet. - wireties [more]
Home
Go Back   Chief Delphi > Technical > Programming > NI LabVIEW
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #4   Spotlight this post!  
Unread 27-09-2015, 09:28
Greg McKaskle Greg McKaskle is offline
Registered User
FRC #2468 (Team NI & Appreciate)
 
Join Date: Apr 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 4,752
Greg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond repute
Re: Need Help With Case Statemet

My first suggestion would be to select the loop containing the logic and click the cleanup button on the toolbar. It is the one with the small broom on it. That way we will be able to se how the logic and variables are attached.

In the attached image, I show three alternate ways to combine the logic and select values. i generally use one of the top two. If it is not only values that are changing, but alternate code, I'll use something more like the bottom one.

By the way, the most important thing is that the code makes sense to you and works correctly. These alternate ways of writing it are suggestions, but be sure you understand them before redoing anything.

I like to do this by writing the code in parallel, right next to the existing code. Then you can look at the old and new side-be-side and reason about it. You can review a truth table, sketch a graph, or whatever helps you to understand it and prove that the old and new code work the same. You can even leave most of the old and new code in, run them and compare the results as you run code.

Greg McKaskle
Attached Thumbnails
Click image for larger version

Name:	From Clipboard.png
Views:	47
Size:	34.3 KB
ID:	19319  
Reply With Quote
 


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 21:22.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi