LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to save acquired images

Hello,

It still isn't working this time 'Error 1 occurred at Check Data Size.vi'. Can you take a look at the attached VI?

 

Thanks

0 Kudos
Message 11 of 12
(1,273 Views)

Sometimes it "helps" to read the Help messages.  Create File with Incrementing Suffix is designed for creating "normal" LabVIEW Files -- it actually opens the file for reading or writing as a member of the File I/O functions.  The Image functions play by different rules -- the IMAQ Write combines File Opening with File Writing, and doesn't use the File Reference.

 

So you have to be clever.  [Note -- I haven't actually tested this, but I'm willing to bet a dime, or a beer during NI Week's Block Diagram Party, that this will work ...].

 

Take the File Name that you want to use, pass it through Create File with Incrementing Suffix, and immediately close the File Reference.  Now take the "Actual Path" (the second output) from Create File with Incrementing Suffix, which is a Path, and should have an "incrementing suffix", and use that as the input to Write PNG File.

 

Bob Schor

 

P.S. -- here's a snippet ...

Incrementing Suffix.png

0 Kudos
Message 12 of 12
(1,257 Views)