iLogic run much longer in windows 10, and multiple excel instances

iLogic run much longer in windows 10, and multiple excel instances

liminma8458
Collaborator Collaborator
3,068 Views
25 Replies
Message 1 of 26

iLogic run much longer in windows 10, and multiple excel instances

liminma8458
Collaborator
Collaborator

We are planing to move our Inventor 2019 into Windows 10 from Windows 7. But something in iLogic is dragging our feet.

 

We use iLogic extensively to control sizes of parts. The iLogic rules read size data from Excel spreadsheet. This process runs very fast in Windows 7,  as shown in the first sample video in about just 1 second. But in Windows 10, it takes 18 second to run the same model, as in the second sample video. We have many similar assembly models to run with iLogic in an automation program, this running time in windows 10 is unacceptable.

 

I notice in the running under windows 7, Task Manager shows no Excel instance; while in windows 10, task manager shows sequential and multiple Excel instances when iLogic runs through each sub components. Is it the reason that the time drains in windows 10? Is there any way or switch to turn off those multiple excel instance as in that machine with windows 7? [I try many ways to find but still don't know why this windows 7 laptop runs so fast without showing excel instance in task manager, it is a regular HP Zbook 15 G2 laptop (i7 4810 cpu, 2.8G Hz,  16G ram, 2G graphics) ]

 

iLogic_run_in_win7_sample1:

https://knowledge.autodesk.com/community/screencast/69552e85-e822-4b49-b80d-8e8d3978dcc9

 

iLogic_run_in_win10:

https://knowledge.autodesk.com/community/screencast/d9fad826-f400-4b5d-9920-be8eb17dcb89

 

Attached are the assembly of this model whose sub-components with iLogic rules. The code for the button is in the Word file. It utilizes the iLogic command of "Regenerate All Rule", and just add a timer to demo how long to run all the rules. You can also simply use iLogic "Regenerate All Rule" command to test how long your machine takes and whether it invokes multiple excel instances in task manager. Please test it and Let me know what you experience. And I am looking for the solution of long running time of iLogic in Windows 10 and what is the setup not to show the multiple excel instances in task manager.

 

Thank you very much!

Thanks
Limin
Inventor pro 2023 64 bit update 5.3; Windows 11 pro 64 bit version 24H2; Office 2013 64 bit

Download iCable in App Store to Create Cables Easily

0 Likes
Accepted solutions (1)
3,069 Views
25 Replies
Replies (25)
Message 2 of 26

chandra.shekar.g
Autodesk Support
Autodesk Support

@liminma8458 

 

Attached dataset contains only assembly and related files. But there is no iLogic rules in it. Please provide iLogic rules to test the behavior and make sure that files are non confidential.

 

Thanks and regards,


CHANDRA SHEKAR G
Developer Advocate
Autodesk Developer Network



0 Likes
Message 3 of 26

liminma8458
Collaborator
Collaborator

Sorry that I miss packing standard nut and washer files. This attached should have all (in Inventor 2019 format). There is no iLogic rule in top assembly file "lv1_ct_assy.iam" . But there is iLogic rule in each sub-assembly and parts except nut and washer. The rules read the size data in the tank_data.xls file to generate new design.

 

Thanks

Thanks
Limin
Inventor pro 2023 64 bit update 5.3; Windows 11 pro 64 bit version 24H2; Office 2013 64 bit

Download iCable in App Store to Create Cables Easily

0 Likes
Message 4 of 26

chandra.shekar.g
Autodesk Support
Autodesk Support

@liminma8458 ,

 

In the system requirement for Inventor 2019, it is mentioned that "64-bit Microsoft® Windows® 10 Anniversary Update (version 1607 or higher)" is recommended for Inventor 2019.

 

https://knowledge.autodesk.com/support/inventor-products/learn-explore/caas/sfdcarticles/sfdcarticle...

 

Can you please install latest updates for windows 10 and check the behavior?

 

Thanks and regards,


CHANDRA SHEKAR G
Developer Advocate
Autodesk Developer Network



0 Likes
Message 5 of 26

liminma8458
Collaborator
Collaborator

I have windows 10,  1803 version installed. Did you test my model and reproduce any of those phenomena?

Thanks

Thanks
Limin
Inventor pro 2023 64 bit update 5.3; Windows 11 pro 64 bit version 24H2; Office 2013 64 bit

Download iCable in App Store to Create Cables Easily

0 Likes
Message 6 of 26

chandra.shekar.g
Autodesk Support
Autodesk Support

@liminma8458 ,

 

Checking with engineering team, I will get back to you after hearing from team.

 

Thanks and regards


CHANDRA SHEKAR G
Developer Advocate
Autodesk Developer Network



0 Likes
Message 7 of 26

liminma8458
Collaborator
Collaborator

Even with Windows 7 64 pro, some machines run very faster without excel instances shown in task manager, others run slower due to excel instances in the task manager. I compare all setup of these machines,  they all configure the same. And I also checked into something like MDI, or SDI, or DDE in registry. They are all in vain. very puzzled!

Thanks
Limin
Inventor pro 2023 64 bit update 5.3; Windows 11 pro 64 bit version 24H2; Office 2013 64 bit

Download iCable in App Store to Create Cables Easily

0 Likes
Message 8 of 26

AlexFielder
Advisor
Advisor

The killer question here is what version of Excel is installed on both Windows 7 and Windows 10 machines? I just re-read your post above mine and you note that you're using Excel 2013- I assume Excel 2013 phones home because licensing, but perhaps not as much as newer releases so I believe my reply below is still relevant:

 

I recently wrote an add-in that uses Excel to import data into Inventor 2019.3 and we also have Excel for Office 365.

 

As you have noted, the time taken for processing Excel documents even on Windows 7 can vary massively and using the version we have, it's down to how Excel is calling home to Microsoft as it opens.

 

If I have recently opened and closed Excel for some other document you might think that it means when Inventor needs it, it would be quicker, but no.

 

I'm not sure of a workable solution that doesn't include either:

a) DNS blocking Excel's access to Microsoft's system when Inventor is running

b) having an instance of Excel always open in the background for the add-in and/or iLogic to use

c) utilising the registry setting that allows Inventor to not use Excel for specific tasks - something I have been loathe to try myself because messing with the Windows Registry = here be dragons.

 

I would love to see Autodesk come up with a solution for this as it drives me and countless customers of ours potty waiting for previously (anecdotally) speedy automations/processes.

0 Likes
Message 9 of 26

liminma8458
Collaborator
Collaborator

Alex,

Your word is a little bit slangy. some of them I may not understand well.

We have standalone Office 2013 home and business across the board for our machines. I also test with a standalone Office 2016 home and business with this code, the same thing (with multiple excel in task manager) happens and running is slow.

Thanks

Thanks
Limin
Inventor pro 2023 64 bit update 5.3; Windows 11 pro 64 bit version 24H2; Office 2013 64 bit

Download iCable in App Store to Create Cables Easily

0 Likes
Message 10 of 26

GeorgK
Advisor
Advisor

If there are a lot of Excel sheets to read I would create an add-in with a reference to Microsoft Excel 16.0 Object Library. This is much quicker.

0 Likes
Message 11 of 26

AlexFielder
Advisor
Advisor

@liminma8458  I just downloaded your example assembly and from the file I created (attached) I can see 9 separate calls to the following Notepad++ regex search parameter:

GoExcel\.CellValue\(.*\.xls

So that may explain the time taken to process this particular assembly as well as the number of Excel instances. (On my Windows 7 system it's already been running 5 minutes and opened 4 5 separate Excel instances and has no signs of finishing soon)

 

I'm honestly not sure if there's a better/more efficient way of linking these files to a spreadsheet but honestly an Addin shouldn't be required to solve this issue.

 

Perhaps building the logic that's present within the Excel file within Inventor would be faster? I can't say for definite without knowledge of the design intent of the logic used.

0 Likes
Message 12 of 26

liminma8458
Collaborator
Collaborator

Something like:

irod_lgth=GoExcel.CellValue(.....)

are basic syntax for iLogic. It is what iLogic develops and facilitates for.

Did you open the top assembly "lv1_ct_assy.iam", then run "Regenerate All Rules" in the iLogic commands? There are  very few data reading (2 or 3 readings) in each part.  I am surprised and wonder why for some machine it takes 1 second to finish all rules under the assembly, for other machines takes 18 second,  for yours will take more than 5 minutes.

Thank you for your testing

Thanks
Limin
Inventor pro 2023 64 bit update 5.3; Windows 11 pro 64 bit version 24H2; Office 2013 64 bit

Download iCable in App Store to Create Cables Easily

0 Likes
Message 13 of 26

MjDeck
Autodesk
Autodesk

@liminma8458 , it could be that on the fast machines you have this environment variable set:
set UseLibXL=1
That will tell iLogic (and Inventor in general) to use the LibXL library instead of the Excel application. That library is much faster, but there are limitations.


Mike Deck
Software Developer
Autodesk, Inc.

0 Likes
Message 14 of 26

liminma8458
Collaborator
Collaborator

Hi, Mike,

What is "set UseLibXL=1"? It doesn't ring a bell to me.  Could you tell me where to check this setting and how to set it? and what is its limitation?

 

In our application, we only read data from Excel, does not write to Excel at all.

 

Thanks

Thanks
Limin
Inventor pro 2023 64 bit update 5.3; Windows 11 pro 64 bit version 24H2; Office 2013 64 bit

Download iCable in App Store to Create Cables Easily

0 Likes
Message 15 of 26

MjDeck
Autodesk
Autodesk

It's a Windows environment variable. You can set it in the Control Panel or at a Command Prompt.

To check it, open a Command Prompt window and type the command:

set use

That will show you all the environment variables that start with the text "use".
On a fast machine, do you see a value for UseLibXL in the list?


Mike Deck
Software Developer
Autodesk, Inc.

0 Likes
Message 16 of 26

MjDeck
Autodesk
Autodesk

Another possibility: Excel is not installed on the fast machines. Or maybe it is installed, but iLogic can't find it. In that case it will default to LibXL.


Mike Deck
Software Developer
Autodesk, Inc.

0 Likes
Message 17 of 26

liminma8458
Collaborator
Collaborator

Wow!!!

I see it in my fast machine. I must set it sometime when I was day dreaming. Do not have any memory on it.

I do the setup in my slow machine. It runs like a charm faster!!!

Thanks a lot, Mike, I know you are an iLogic guru!

 

Should I populate the setup to all machines? what is the known limitation for this variable?

 

Capture.PNG

Thanks
Limin
Inventor pro 2023 64 bit update 5.3; Windows 11 pro 64 bit version 24H2; Office 2013 64 bit

Download iCable in App Store to Create Cables Easily

0 Likes
Message 18 of 26

MjDeck
Autodesk
Autodesk
Accepted solution

Here are the main limitations of LibXL for iLogic:
- no support for embedded spreadsheets
- no Excel calculation after you use iLogic to write to a new value to a cell
- the GoExcel.Application object is not available

We plan to support embedded spreadsheets in a future release.

Since you're not writing to Excel, the second item shouldn't be a problem for you. 
LibXL provides the ability to read and write Excel files. But there's no Excel engine running. That's why calculations don't happen. But you can write to a file and then later open it manually in Excel and it will recalculate if necessary.
Maybe you're not using the Excel.Application object, which provides full Excel API access.

In addition to iLogic, the UseLibXL option also applies to other Inventor uses of Excel. It should be reliable for linked parameters, iPart tables, and other uses. And it's faster. But there might be some Excel use cases that are not fully supported. Let me follow up on that question.

 


Mike Deck
Software Developer
Autodesk, Inc.

0 Likes
Message 19 of 26

liminma8458
Collaborator
Collaborator

Thank all of you very much!

Thanks
Limin
Inventor pro 2023 64 bit update 5.3; Windows 11 pro 64 bit version 24H2; Office 2013 64 bit

Download iCable in App Store to Create Cables Easily

0 Likes
Message 20 of 26

liminma8458
Collaborator
Collaborator

Hi, Mike,

One extra request: is it possible and have any way we can use

GoExcel.CellValue(.....)

syntax in VB.NET code? or does Autodesk has any plan to open this syntax as iLogic API so it can be used in VB.NET code. So it will save programmer a lot of job work to deal with reading from Excel spreadsheet.

 

Thanks

Thanks
Limin
Inventor pro 2023 64 bit update 5.3; Windows 11 pro 64 bit version 24H2; Office 2013 64 bit

Download iCable in App Store to Create Cables Easily

0 Likes