07-12-2017 06:42 PM - edited 07-12-2017 06:42 PM
This problem is driving me insane...I don't even know how to word it or how to Google the problem, please bear with me.
Here is the simplified background: we test sample1, sample2, sample3, etc. and generate sample1data, sample2data, sample3data, etc.
I have a LabVIEW (2011) code that processes these data and generates some PNG plots (for each sample). Then it takes these plots (already saved in some folder) and inserts them into an MS PowerPoint (I have a PowerPoint template), then it names the PowerPoint after the sample, for example, sampe1data.ppt, sample2data.ppt, sample3data.ppt, etc.
Now the problem is that if I open sample1data.ppt (for further editing by hand), and then open sample2data.ppt, the sample2data.ppt shows exactly the same things as sample1data.ppt, and if I open sample3data.ppt, it also shows the exact same things as sample1data.pp1. So all three ppts SHOW the exact same content.
HOWEVER, if I take these 3 ppts. which are in some folder and move the folder to a different location (say a network drive), and then open each ppt. from that location, then each ppt. opens (in Read Only Mode) and displays the correct information. BUT, the moment I click on "Enable Edit" button on the ppts, they all again show the exact same information.
When I save the ppt., I do close the reference to it inside LabVIEW. I have no idea where to begin to tackle this issue. I don't even know how to Google this problem. Has anyone seen this before. Any help is appreciated. Thanks.
07-12-2017 06:56 PM
Can you post the code you use to generate the .ppt files?
07-12-2017 06:59 PM
Here is the part that same the ppt.
07-12-2017 07:11 PM
Hmm... I mostly use the report generation toolkit when dealing with Office. If you diligently close your references (Shapes, _Slide, Slides, _Presentation, _Application) does it make any difference?
07-20-2017 06:29 PM
Here is how I closed the references. Didn't help.
07-20-2017 09:33 PM
07-21-2017 01:32 PM
I hadn't connected anything to the "untitled" input, so it was using the default setting.
When I right-clicked on it to create a constant, it created by default msoTrue. So clearly, the default is msoTrue. So probably that doesn't change anything.
07-21-2017 02:39 PM
@murchak wrote:
I hadn't connected anything to the "untitled" input, so it was using the default setting.
When I right-clicked on it to create a constant, it created by default msoTrue. So clearly, the default is msoTrue. So probably that doesn't change anything.
Not according to the Microsoft documentation.
Ben64
07-21-2017 04:01 PM
@murchak wrote:
Here is how I closed the references. Didn't help.
I doubt this is the cause of the problem but the references that are opened inside the FOR loop (_Slide and Shapes) should by closed inside the FOR loop. Right now only the last opened references get closed.
Ben64