From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

Using the NI Community

cancel
Showing results for 
Search instead for 
Did you mean: 

Tips for Posting Code for Troubleshooting

When posting code for troubleshooting, please keep these tips in mind:

 

Do not post screenshots of code.

Upload the actual VI, or zip several files and upload the zip.

The exception to this rule is when uploading a VI Snippet.

 

When uploading source code, attach your source code in the form of a ZIP

Include relevant source code files *.c, include files *.h, UI files *.uir, possibly the project file *.prj or *.cws
Do NOT upload the executable

 

Do not just post a project file. This has no source and will be of no use without the rest of the files.

Include all subVIs, typedefs, global variables, project files, and any other files you made to run the VI.

 

Do not post code that is password protected.

 

Do not include anything from vi.lib or that is part of a standard LabVIEW installation.

 

Do not include libraries from commercial third party drivers unless you suspect them to be the cause of the problem.

 

If you attach more than one VI, mention which VI is the top level.

 

Do not set indicators to new default values, especially graphs containing large amounts of data.

Set all controls to typical values, then make them default before saving.

 

The default data should be typical and not biased in any way.

If an input is a matrix, don't make it square or symmetric unless that is guaranteed to always be the case.

 

If the problem is with reading a file, include a sample file that demonstrates the problem.

 

If you run the newest LabVIEW version, you might want to down convert to a lower version before attaching.

This way there are more people that can potentially help. This is only recommended if you suspect that the issue isn't version specific.

 

Do not set your VI to "Run when Opened" unless that is necessary to demonstrate the problem.

Please provide a WARNING in your post if this attachment will run when opened.

 

Please provide a WARNING in your post if the code will not exit normally when run. Users may have their own projects open and be working on it. 

If your VI crashes LabVIEW, a warning will help remind us to save our code before helping you with your problem.

 

--------

 

Remember, by providing your code in a VI or compressed zip of multiple VIs/projects, it helps with the following:

  • Users know what you have already attempted
  • Users know which version of LabVIEW you are using
  • Users can immediately test and try out your code, seeing what errors it shows, and it gives users a place to "start tinkering"
  • Users get an indication of the level you are working at, allowing users to respond more appropriately

 

For more tips on information to provide when posting a new topic, please refer to: Help Us Help You When Posting New Topics

 

 

Special thank you to Hooovahh and all those that contributed to the source!

~~~~~~~~~
Message 1 of 1
(3,800 Views)