Worf

TypeScript objects and Excel tables

Worf

Well-known Member
Joined
Oct 30, 2011
Messages
4,261
Worf submitted a new Excel article:

TypeScript objects and Excel tables - This article shows how to manipulate tables with TypeScript.

Certain Excel 365 licenses offer Office scripts, which is an implementation of the TypeScript language to automate Excel, just like VBA does.

I am planning a small series of articles focusing on relevant TS features and their application to the Excel object model; this first one will deal with TS objects and Excel tables.

On the TS side, here are some of the topics covered:

  • Two different objects are defined, with the final table type being a union type of those two.
  • The style...

Read more about this Excel article...
 

Excel Facts

Save Often
If you start asking yourself if now is a good time to save your Excel workbook, the answer is Yes
@Worf - this is the first instance I've found that creates a slicer in TypeScript. I'm very new to TypeScript (like many I expect!) and I wonder if you could help me understand how/why the slicer created is column 2 from the table (created, with values; 95, Jones, last).
 
ok - don't worry, I've found the relevant part of the script and understand now. I do have a follow up though. I am also trying to add a slicer, however, it is for a Power Pivot rather than a flat table. The TypeScript recorder doesn't record the action so I can't obtain code that way and I haven't yet found anything on the web to help. I suspect Power Pivot isn't (yet) compatible with TypeScript, but I haven't seen that confirmed anywhere either.

Do you know if it is possible to access/manipulate a Power Pivot model using TypeScript?
 
Hi

Unfortunately my company disabled Excel scripts for me so I currently cannot test anything. :mad:
 
Hi

Unfortunately my company disabled Excel scripts for me so I currently cannot test anything. :mad:
Thanks for taking the time to reply. If I find a solution I'll update
 

Forum statistics

Threads
1,224,825
Messages
6,181,190
Members
453,020
Latest member
Mohamed Magdi Tawfiq Emam

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top