YetAnotherForum
Welcome Guest Search | Active Topics | Log In | Register

Excel does not open with Add in for Pi Process book Options · View
mric
#1 Posted : Saturday, February 04, 2012 10:40:43 PM
Rank: Newbie
Groups: Member

Joined: 11/3/2011
Posts: 7
Location: México
Hello again:
Im openning an Excel workbook from Pi processbook via macro:

Set xlApp = CreateObject("Excel.Application")
xlApp.Visible = True

When Excel is already Open, this has not the Adds In for PI and cannot read values or refresh in Excel.
How can I connect to Pi server if does not have the Add in on the menu tools bar in Excel program?Think
Thanks
Sponsor  
 

OSIsoft vCampus is a subscription-based, online offering that consists of providing everything people need to develop applications on the PI System.
We invite you to take a "tour" of the OSIsoft Virtual Campus - also feel free to consult the FAQ  or contact OSIsoft vCampus for more details.
caffreys_col
#2 Posted : Wednesday, February 15, 2012 10:09:40 AM
Rank: Advanced Member
Groups: Member

Joined: 4/6/2011
Posts: 40
Location: Grimsby UK
Hi mric,

I'm assuming your talking about the PI Datalink add-in for Excel. If so is the PI batchiview for Excel add-in also one of the selected add-ins trying to be loaded when Excel starts? If thats the case then it could be that which is stopping the datalink add-in from loading. On our Excel installations if the PI Batchview add-in for Excel is checked to be loaded then it stops PI datalink being loaded - you end up with only Batch search onthe PI menu list.
Uncheck PI batchivew for Excel in your list of add-ins for Excel and it should work.

If the problem is that you are not seeing a PI menu option at all then make sure that the PI datalink add-in is "checked" in your list of add-ins (Tools->add-ins).

Does the add-in show when you open Excel normally from the desktop?? If not check you don't have any files in the xlstart directory. Any files in this directory are automatically opened when you start Excel and this can cause issues with add-ins.

Hope some of this helps.
zfima
#3 Posted : Wednesday, February 15, 2012 10:25:35 AM
Rank: Advanced Member

Groups: Member

Joined: 11/13/2011
Posts: 77
Location: Middle East
Check it : microsoft
mric
#4 Posted : Wednesday, February 15, 2012 2:47:30 PM
Rank: Newbie
Groups: Member

Joined: 11/3/2011
Posts: 7
Location: México
Hello caffreys_col:
This happen only when excel is opening from Pi Process book (Does not show PI), but when Opening the Excel file directly PI , is present in Add ins.
Thanks a lot.
RJK Solutions
#5 Posted : Thursday, February 16, 2012 10:01:35 AM
Rank: Administration

Groups: Administration

Joined: 6/20/2008
Posts: 617
Location: Cheshire, United Kingdom.
When using automation to create Excel Applications you need to explicitly load any addins, in particular the pipc32.xll addin.

xlApp.RegisterXLL ("C:\Program Files\PIPC\Excel\pipc32.xll") ' If you have installed to a different directory, then amend the path to the addin.

Another thread on here that has had a similar problem:
http://www.rjksolutionsl...e-using-vbs-wscript.aspx
Principal Consultant
Real-Time Data Management @ Wipro Technologies
mric
#6 Posted : Thursday, February 16, 2012 11:37:48 AM
Rank: Newbie
Groups: Member

Joined: 11/3/2011
Posts: 7
Location: México
Hello.
Thanks again.
This works :XLApp.RegisterXLL ("C:\Program Files\PIPC\Excel\pipc32.xll") fine for add in.
Thanks, I will not use Excell, cause the program open and reopen every refresh and everytime the pop up for login piuser on Excel.
I will read directly from tags on Pi processbook. long way but easy way Smile
But a way How can I make an array for tags reading in a loop in Pi Process book?
Thanks again.
caffreys_col
#7 Posted : Tuesday, February 21, 2012 9:11:01 AM
Rank: Advanced Member
Groups: Member

Joined: 4/6/2011
Posts: 40
Location: Grimsby UK
Reading tags as an array... why would you do this in Processbook? What are you trying to display?? Are you using a trend or just showing individual values for each PI tag?? Without knowing more about what you want to display, (and how) I am reluctant to suggest anything as it could be totally useless for what you need.
mric
#8 Posted : Tuesday, February 21, 2012 4:24:27 PM
Rank: Newbie
Groups: Member

Joined: 11/3/2011
Posts: 7
Location: México
Hello:
Actually Im using Excel with a lot of tags reading, I would like to use Pi Processbook using a Display an overview of all the Plant, and all critical tags that wilil trip any unit, pumps trip or anything else trip.
Using Pi Processbook is easy way than use excel due Excel interferes with others books when macro is runing.
Im Putting each tag in processbook and reading one by one, when any alarm is present read the value and alarm. Is there anyway to make an array?


Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.