If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > PC based Database Applications > Microsoft Excel > Problem with access to Workbook.PivotCaches method from JScript

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 03-10-05, 09:57
Belgrad Belgrad is offline
Registered User
 
Join Date: Mar 2005
Posts: 8
Problem with access to Workbook.PivotCaches method from JScript

Hello, guys!

Can anyone help me with a strange thing? Access to PivotCaches method of Workbook object doesn't work in JScript and does in VB. WSH throws an exception "Object doesn't support this property or method"

This code doesn't work:

var excel = new ActiveXObject("Excel.Application");
var wb = excel.Workbooks.Add();

WScript.Echo( wb.pivotcaches.count );


But this code does:

set excel = CreateObject("Excel.Application")
set wb = excel.workbooks.add

WScript.Echo( wb.pivotcaches.count )


Either this is a bug somewhere in Excel automation or I am complete idiot...
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On