bimbim Posted November 30, 2005 Report Share Posted November 30, 2005 Hi, I've build a VI to read all sheets in an Excel file. It works well but when I'm using it in another VI and that I access the same Excel file, for example with the delete file VI, an error is generated. If the two VI are used separatly, no problem occurs. I attach the VI I'm using to test the availability of the Excel file after the read operation is completed. The erasing of the file doesn't work, but some other actions can't be done (save, etc.). It seems as if an opened reference is not closed (even if I've tried to do to my best to close them all !) I know the report generation toolkit exists but we don't have any money to spend in this solution that don't correspond to our needs. I'd be grateful if someone could tell me what is going wrong in my VI, I's been a long time I've been trying and all my ideas failed for the moment... Thank you in advance for your help. Bim Download File:post-1776-1133362018.llb Quote Link to comment
Mike Ashe Posted December 1, 2005 Report Share Posted December 1, 2005 Just a quick guess, I didn't test it, but in VI: "XLspecial_GetAllExcelData.vi" you have a FOR loop where you create references to each sheet in the workbook, but on the right side of the loop you have indexing disabled on the references coming out, so the Close Reference nodes only close the last reference(s) generated by the loop. The rest might be left dangling. You might want to enable referencing and enclose those Close REfs in another loop, or pull them into your current FOR loop. Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.