I am working on a requirement and I am facing an issue for which I need help to resolve.
I have 9000 PI tags. They are digital tags with value "Not-Active" or "Active".
Daily morning once and evening once I have to generate an excel sheet with the tag names of all the tags with value as "Active".
I am using VBA and PI datalink to achieve this. I have a master excel with all 9000 tags in one column and their corresponding current values in the 2nd column.
Then using macros I identify the active tags and publish their names into another excel.
When I manually open my excel I am able to perform these functions as expected and designed. But when I use task scheduler to open the excel for me, I see Pi datalink doesnt load and due to this the "active" and "nonActive" values are not there. This causes error and my macro doesnt run. Please advice me on how to resolve this. I am attaching the screens below.
Screen1. Macro written in the main file where the two columns are tag names and current values.
Screen 2. Error I face when I open this macro enabled file using task scheduler.
Please help me how can I automatically open my excel on two different scheduled slots in the day and get the desired result.
Thank you in advance.