1 Excel

Class Ax.ms.Excel


This class represents an Excel workbook. Wrapper for Apache POI Workbook. EXAMPLES: https://github.com/jbolaky/multi-java-frameworks-tutorials/tree/master/apache-poi/src/main/java/org/apache/poi/xssf/usermodel/examples Charts using JFreeChart http://thinktibits.blogspot.com/2012/12/Create-Bar-Chart-Excel-Java-Example-Program-POI-JFreeChart-Tutorial.html PPT chart https://github.com/cuba-platform/apache-poi/blob/master/poi/src/examples/src/org/apache/poi/xslf/usermodel/PieChartDemo.java ExcelReporter https://github.com/TTAutomation/HQA/blob/master/CBF-2.5.6/src/cbf/reporting/ExcelReporter.java

Constructor Summary

Method
Description
Creates a new Excel workbook.
Creates a new excel workbook of the selected type.
JSExcelWorkbook(Ax.text.String name)
Creates a new excel workbook with the specified name.
JSExcelWorkbook(ExcelType type, Ax.text.String name)
Creates a new excel workbook of the selected type, with the specified name.

Method Summary

Modifier and Type
Method
Description
Reports what (if any) formula functions used are not (currently) supported by Apache POI.
cloneSheet(Ax.text.String sheetName)
Creates a sheet from the sheet with the given name in the Workbook.
cloneSheet(int sheetNum)
Creates a sheet from the sheet in the given index in the Workbook.
Ax.text.String 
columnToString(int col)
Returns the Excel column letter/s corresponding to the column number.
Creates a new excel cell style.
Creates a new excel font.
createSheet(Ax.text.String name)
Creates a new sheet with the given name.
createSheet(Ax.text.String name,Consumer<SheetCreateOptions> options)
Creates a sheet and fills it with given data producing a header with column names and named cells.
Returns a DBExport for the given workbook.
Returns a DBImport for the given workbook.
int 
delete(Ax.text.String tableName)
Deletes the table.
int 
delete(Ax.text.String tableName,int numRowsToDelete)
Deletes the table.
List 
diff(Ax.ms.Excel other)
Returns a list of the differences between this Wb an other.
void 
dump()
A debug to standard output of the contents of the workbook to inspect each sheet's content.
void 
Recalculates all formulas in a Workbook.
void 
forEach(Consumer arg0)
getCellByName(Ax.text.String name)
Returns a named cell by its name.
org.apache.poi.ss.usermodel.CellStyle 
Returns a cell style for dates, to avoid the creation of a new style for each date in a cell, as there is a limit number of cell styles (4000 in .
org.apache.poi.ss.usermodel.CellStyle 
Returns a cell style for links / URLs, to avoid the creation of a new style for each cell, as there is a limit number of cell styles (4000 in .
org.apache.poi.ss.usermodel.CellStyle 
Returns a cell style to align the content of cells to th right, to avoid the creation of a new style for each cell, as there is a limit number of cell styles (4000 in .
Ax.text.String 
Gets the name of this excel workbook.
int 
getNamedRow(Ax.text.String tableName)
Returns the starting row for named cells in rectangular format.
int 
Gets the number of sheets of this workbook.
getSheet(int index)
Returns the sheet at the index position (starting by 0).
getSheet(Ax.text.String name)
Returns the sheet by its name.
getSheetAt(int index)
Returns the sheet at the index position (starting by 0).
Gets the excel type.
Returns an iterator over the sheets of this excel workbook.
Ax.ms.Excel 
load(Object src)
Loads an excel workbook from a source.
Ax.ms.Excel 
load(byte[] data)
Loads an excel workbook from a byte array.
long 
Updates (adding +1) and returns the column id number for table columns created in any sheet.
long 
Updates (adding +1) and returns the table id number for tables created in any sheet.
void 
Resets the current evaluator.
File 
save(Ax.text.String name)
Returns this workbook as an excel file.
select(Consumer<SQLSelectOptions> configurator)
Returns a ResultSet of a query on this workbook.
void 
Sets column auto-sizing, that is, the columns will be as wide as the longest value needs to be completely seen.
void 
setEvaluatorCache(boolean cache)
Sets whether the evaluator will have cache or not.
void 
setEvaluatorDebug(boolean debug)
TODO!! does not work!! Sets the evaluator debug loggging.
void 
Whether the application shall perform a full recalculation when the workbook is opened.
void 
setName(Ax.text.String name)
Sets the name of this excel workbook.
toBlob()
Returns this workbook as a BLOB.
Ax.text.String 
toCell(int row, int col)
Returns a String of the cell reference (like "A1" for column A and row 1 in Excel) from the row and column indexes.
org.apache.poi.ss.util.CellReference 
toCellReference(int row,int col)
Returns the cell reference (like "A1" for column A and row 1 in Excel) from the row and column indexes.
int 
update(Map<ObjectObject> map, Consumer<SQLOptions> configurator)
Updates all columns from the Map into workbook named cells.
int 
Updates all columns from the ResultSet into workbook named cells.

Constructor Detail

Ax.ms.Excel.JSExcelWorkbook

Ax.ms.Excel.JSExcelWorkbook()
Info:
Creates a new Excel workbook.

Ax.ms.Excel.JSExcelWorkbook

Ax.ms.Excel.JSExcelWorkbook(
	object type
						)
Info:
Creates a new excel workbook of the selected type. The excel types are: HSSF (.xls extension), XSSF and SXSSF (.xlsx extension). To use in JS: Ax.ms.Excel.Type.XSSF
Parameters:
type - the excel type

Ax.ms.Excel.JSExcelWorkbook

Ax.ms.Excel.JSExcelWorkbook(
	string name
						)
Info:
Creates a new excel workbook with the specified name.
Parameters:
name - the workbook name

Ax.ms.Excel.JSExcelWorkbook

Ax.ms.Excel.JSExcelWorkbook(
	object type,
	string name
						)
Info:
Creates a new excel workbook of the selected type, with the specified name. The excel types are: HSSF (.xls extension), XSSF and SXSSF (.xlsx extension). Format to use in JS: Ax.ms.Excel.Type.XSSF
Parameters:
type - the excel type
name - the workbook name

Example
Copy
let wb = new Ax.ms.Excel(Ax.ms.Excel.Type.XSSF, "Workbook");

Method Detail

Ax.ms.Excel.checkFunctionsSupported

object Ax.ms.Excel.checkFunctionsSupported()
Info:
Reports what (if any) formula functions used are not (currently) supported by Apache POI.
Returns:
object

Ax.ms.Excel.cloneSheet

object Ax.ms.Excel.cloneSheet(
	string sheetName
)
Info:
Creates a sheet from the sheet with the given name in the Workbook.
Parameters:
sheetName - name of the sheet to clone
Returns:
object

Ax.ms.Excel.cloneSheet

object Ax.ms.Excel.cloneSheet(
	smallint sheetNum
)
Info:
Creates a sheet from the sheet in the given index in the Workbook.
Parameters:
sheetNum - name of the sheet to clone
Returns:
object

Ax.ms.Excel.columnToString

string Ax.ms.Excel.columnToString(
	smallint col
)
Info:
Returns the Excel column letter/s corresponding to the column number.
Parameters:
col - the column number
Returns:
string

Ax.ms.Excel.createCellStyle

object Ax.ms.Excel.createCellStyle()
Info:
Creates a new excel cell style.
Returns:
object

Ax.ms.Excel.createFont

object Ax.ms.Excel.createFont()
Info:
Creates a new excel font.
Returns:
object

Ax.ms.Excel.createSheet

object Ax.ms.Excel.createSheet(
	string name
)
Info:
Creates a new sheet with the given name. Sheet name mut e unique on the workbook.
Parameters:
name - the name of the new sheet
Returns:
object

Ax.ms.Excel.createSheet

object Ax.ms.Excel.createSheet(
	string name,
	object options
)
Info:
Creates a sheet and fills it with given data producing a header with column names and named cells.
Parameters:
name - the name of the new sheet
options - the creation configuration function
Returns:
object

Ax.ms.Excel.dbexport

object Ax.ms.Excel.dbexport()
Info:
Returns a DBExport for the given workbook.
Returns:
object

Ax.ms.Excel.dbimport

object Ax.ms.Excel.dbimport()
Info:
Returns a DBImport for the given workbook.
Returns:
object

Ax.ms.Excel.delete

smallint Ax.ms.Excel.delete(
	string tableName
)
Info:
Deletes the table.
Parameters:
tableName - the name of the table to delete
Returns:
smallint

Ax.ms.Excel.delete

smallint Ax.ms.Excel.delete(
	string tableName,
	smallint numRowsToDelete
)
Info:
Deletes the table.
Parameters:
tableName - the name of the table to delete
numRowsToDelete - the number of rows to delete
Returns:
smallint

Ax.ms.Excel.diff

array Ax.ms.Excel.diff(
	object other
)
Info:
Returns a list of the differences between this Wb an other.
Parameters:
other - the other workbook to compare
Returns:
array

Ax.ms.Excel.dump

null Ax.ms.Excel.dump()
Info:
A debug to standard output of the contents of the workbook to inspect each sheet's content.
Returns:
null

Ax.ms.Excel.evaluate

null Ax.ms.Excel.evaluate()
Info:
Recalculates all formulas in a Workbook.
Returns:
null

Ax.ms.Excel.forEach

null Ax.ms.Excel.forEach(
	object arg0
)
Parameters:
arg0 - 
Returns:
null

Ax.ms.Excel.getCellByName

object Ax.ms.Excel.getCellByName(
	string name
)
Info:
Returns a named cell by its name.
Parameters:
name - the cell name
Returns:
object

Ax.ms.Excel.getCellStyleDate

object Ax.ms.Excel.getCellStyleDate()
Info:
Returns a cell style for dates, to avoid the creation of a new style for each date in a cell, as there is a limit number of cell styles (4000 in .xls workbooks).
Returns:
object

Ax.ms.Excel.getCellStyleHref

object Ax.ms.Excel.getCellStyleHref()
Info:
Returns a cell style for links / URLs, to avoid the creation of a new style for each cell, as there is a limit number of cell styles (4000 in .xls workbooks).
Returns:
object

Ax.ms.Excel.getCellStyleRightAligned

object Ax.ms.Excel.getCellStyleRightAligned()
Info:
Returns a cell style to align the content of cells to th right, to avoid the creation of a new style for each cell, as there is a limit number of cell styles (4000 in .xls workbooks).
Returns:
object

Ax.ms.Excel.getName

string Ax.ms.Excel.getName()
Info:
Gets the name of this excel workbook.
Returns:
string

Ax.ms.Excel.getNamedRow

smallint Ax.ms.Excel.getNamedRow(
	string tableName
)
Info:
Returns the starting row for named cells in rectangular format.
Parameters:
tableName - the table name
Returns:
smallint

Ax.ms.Excel.getNumberOfSheets

smallint Ax.ms.Excel.getNumberOfSheets()
Info:
Gets the number of sheets of this workbook.
Returns:
smallint

Ax.ms.Excel.getSheet

object Ax.ms.Excel.getSheet(
	smallint index
)
Info:
Returns the sheet at the index position (starting by 0). Same as getSheetAt().
Parameters:
index - 
Returns:
object

Ax.ms.Excel.getSheet

object Ax.ms.Excel.getSheet(
	string name
)
Info:
Returns the sheet by its name.
Parameters:
name - 
Returns:
object

Ax.ms.Excel.getSheetAt

object Ax.ms.Excel.getSheetAt(
	smallint index
)
Info:
Returns the sheet at the index position (starting by 0). Same as getSheet().
Parameters:
index - 
Returns:
object

Ax.ms.Excel.getType

object Ax.ms.Excel.getType()
Info:
Gets the excel type. The excel types are: HSSF (.xls extension), XSSF and SXSSF (.xlsx extension).
Returns:
object

Ax.ms.Excel.iterator

object Ax.ms.Excel.iterator()
Info:
Returns an iterator over the sheets of this excel workbook.
Returns:
object

Ax.ms.Excel.load

object Ax.ms.Excel.load(
	object src
)
Info:
Loads an excel workbook from a source.
Parameters:
src - source: (blob |byte[] | inputStream | string[ url, base64 or filename ])
Returns:
object

Example
Copy
var wb = Ax.ms.Excel.load("http://courses.washington.edu/hcde511/s14/datasets/cars.xls");

Ax.ms.Excel.load

object Ax.ms.Excel.load(
	byte[] data
)
Info:
Loads an excel workbook from a byte array.
Parameters:
data - bytes containing the workbook
Returns:
object

Ax.ms.Excel.nextColumnId

long Ax.ms.Excel.nextColumnId()
Info:
Updates (adding +1) and returns the column id number for table columns created in any sheet.
Returns:
long

Ax.ms.Excel.nextTableId

long Ax.ms.Excel.nextTableId()
Info:
Updates (adding +1) and returns the table id number for tables created in any sheet.
Returns:
long

Ax.ms.Excel.resetEvaluator

null Ax.ms.Excel.resetEvaluator()
Info:
Resets the current evaluator.
Returns:
null

Ax.ms.Excel.save

file Ax.ms.Excel.save(
	string name
)
Info:
Returns this workbook as an excel file.
Parameters:
name - the excel file containing this workbook
Returns:
file

Ax.ms.Excel.select

resultset Ax.ms.Excel.select(
	object configurator
)
Info:
Returns a ResultSet of a query on this workbook.
Parameters:
configurator - the select configuration function
Returns:
resultset

Example
Copy
rs = wb.select(options => {
     options.setTableName("tabname");
     options.setEvaluate(false);
 });

Ax.ms.Excel.setAutoSizeColumns

null Ax.ms.Excel.setAutoSizeColumns()
Info:
Sets column auto-sizing, that is, the columns will be as wide as the longest value needs to be completely seen.
Returns:
null

Ax.ms.Excel.setEvaluatorCache

null Ax.ms.Excel.setEvaluatorCache(
	boolean cache
)
Info:
Sets whether the evaluator will have cache or not.
Parameters:
cache - whether the evaluator will use cache or not
Returns:
null

Ax.ms.Excel.setEvaluatorDebug

null Ax.ms.Excel.setEvaluatorDebug(
	boolean debug
)
Info:
TODO!! does not work!! Sets the evaluator debug loggging.
Parameters:
debug - whether the debug logging is in use
Returns:
null

Ax.ms.Excel.setForceFormulaRecalculation

null Ax.ms.Excel.setForceFormulaRecalculation(
	boolean force
)
Info:
Whether the application shall perform a full recalculation when the workbook is opened. Typically you want to force formula recalculation when you modify cell formulas or values of a workbook previously created by Excel. When set to true, this flag will tell Excel that it needs to recalculate all formulas in the workbook the next time the file is opened.
Parameters:
force - whether all formulas in the workbook need to be recalculated the next time the file is opened
Returns:
null

Ax.ms.Excel.setName

null Ax.ms.Excel.setName(
	string name
)
Info:
Sets the name of this excel workbook.
Parameters:
name - 
Returns:
null

Ax.ms.Excel.spliterator

object Ax.ms.Excel.spliterator()
Returns:
object

Ax.ms.Excel.toBlob

object Ax.ms.Excel.toBlob()
Info:
Returns this workbook as a BLOB.
Returns:
object

Ax.ms.Excel.toCell

string Ax.ms.Excel.toCell(
	smallint row,
	smallint col
)
Info:
Returns a String of the cell reference (like "A1" for column A and row 1 in Excel) from the row and column indexes.
Parameters:
row - row index
col - column index
Returns:
string

Ax.ms.Excel.toCellReference

object Ax.ms.Excel.toCellReference(
	smallint row,
	smallint col
)
Info:
Returns the cell reference (like "A1" for column A and row 1 in Excel) from the row and column indexes.
Parameters:
row - row index
col - column index
Returns:
object

Ax.ms.Excel.update

smallint Ax.ms.Excel.update(
	object map,
	object configurator
)
Info:
Updates all columns from the Map into workbook named cells.
Parameters:
map - a map(JSON) of values probably passed from javascript; to support ScriptObjectMirror as argument we must accept Map < Object, Object > as argument
configurator - the update configuration function
Returns:
smallint

Example
Copy
var map = {}
 var wb = new Ax.ms.Excel();
 wb.update(map, options => {
 options.setTableName("table");
 });

Ax.ms.Excel.update

smallint Ax.ms.Excel.update(
	object rsconv,
	object configurator
)
Info:
Updates all columns from the ResultSet into workbook named cells.
Parameters:
rsconv - Resultset to update
configurator - update configuration function
Returns:
smallint

2 Word

Class Ax.ms.Word


This class represents a MS Word document. Wrapper for Apache POI XWPFDocument. The target samples https://plumsail.com/docs/actions/v1.x/document-generation/docx/demos.html A more complete doc system (with loop capabilities) is: http://obeonetwork.github.io/M2Doc/ref-doc/nightly/index.html http://www.dskims.com/how-to-copy-a-paragraph-of-docx-to-another-docx-withjava-and-retain-the-style/ WhiteRabbit https://github.com/OHDSI/WhiteRabbit DocumentVisitor https://github.com/INL/OpenConvert/blob/master/src/org/apache/poi/xwpf/converter/core/XWPFDocumentVisitor.java Binary preorder-traversal https://javarevisited.blogspot.com/2016/07/binary-tree-preorder-traversal-in-java-using-recursion-iteration-example.html

Constructor Summary

Method
Description
JSWord()
Creates a new Word document.
JSWord(Ax.text.String name)
Creates a new Word document with the specified name
JSWord(Ax.text.String name, org.apache.poi.xwpf.usermodel.XWPFDocument object)
Creates a new Word document with the specified name from a source XWPFDocument.

Method Summary

Modifier and Type
Method
Description
void 
addPageBreak(Ax.ms.Word doc)
Adds a page break to the document.
void 
addPageBreak(org.apache.poi.xwpf.usermodel.XWPFDocument doc)
Adds a page break to the document.
Ax.text.String 
Returns the contents of this Word document.
Creates a new paragraph on this document, appended to the previous ones.
Creates a new table on this Word document.
Creates a new table on the Word document from a ResultSet.
Creates a new table on the Word document from a ResultSet.
void 
dump()
Prints (dumps) all the contents of the paragraphs and the tables of this Word document.
Ax.text.String 
Gets this document's name.
List 
Gets a list of all the paragraphs in the word document.
Ax.text.String 
Gets all the text of this Word document, that is, a concatenation of all the text fragments of the different parts of the document, headers included.
Ax.ms.Word 
load(Object src)
Loads a word document from a source object.
print(Ax.text.String value)
Creates a new text paragraph and a new run in that paragraph.
void 
scanParagraph(org.apache.poi.xwpf.usermodel.IBodyElement element)
Prints (dumps) all the contents of the paragraphs of this document.
void 
scanTable(org.apache.poi.xwpf.usermodel.IBodyElement element)
Prints (dumps) all the contents of the tables of this document.
void 
setName(Ax.text.String name)
Sets this document's name.
toBlob()
Converts this Word document to a BLOB object.
int 
toEMU(double points)
Converts points to EMUs (English Metric Unit).
Ax.ms.Word 
update(jdk.nashorn.api.scripting.JSObject data)
Updates this word document with the contents of a JSON.

Constructor Detail

Ax.ms.Word.JSWord

Ax.ms.Word.JSWord()
Info:
Creates a new Word document.

Ax.ms.Word.JSWord

Ax.ms.Word.JSWord(
	string name
						)
Info:
Creates a new Word document with the specified name
Parameters:
name - document name

Example
Copy
var document = new Ax.ms.Word("Document.docx");

Ax.ms.Word.JSWord

Ax.ms.Word.JSWord(
	string name,
	object object
						)
Info:
Creates a new Word document with the specified name from a source XWPFDocument.
Parameters:
name - document name
object - source XWPFDocument

Method Detail

Ax.ms.Word.addPageBreak

null Ax.ms.Word.addPageBreak(
	object doc
)
Info:
Adds a page break to the document.
Parameters:
doc - document to add the page break to
Returns:
null

Ax.ms.Word.addPageBreak

null Ax.ms.Word.addPageBreak(
	object doc
)
Info:
Adds a page break to the document.
Parameters:
doc - document to add the page break to
Returns:
null

Ax.ms.Word.asString

string Ax.ms.Word.asString()
Info:
Returns the contents of this Word document. It iterates through all the runs of the paragraphs and all the cells of the tables.
Returns:
string

Ax.ms.Word.createParagraph

object Ax.ms.Word.createParagraph()
Info:
Creates a new paragraph on this document, appended to the previous ones.
Returns:
object

Ax.ms.Word.createTable

object Ax.ms.Word.createTable()
Info:
Creates a new table on this Word document.
Returns:
object

Ax.ms.Word.createTable

object Ax.ms.Word.createTable(
	object rs
)
Info:
Creates a new table on the Word document from a ResultSet.
Parameters:
rs - source ResultSet
Returns:
object

Ax.ms.Word.createTable

object Ax.ms.Word.createTable(
	resultset rs
)
Info:
Creates a new table on the Word document from a ResultSet.
Parameters:
rs - source ResultSet
Returns:
object

Ax.ms.Word.dump

null Ax.ms.Word.dump()
Info:
Prints (dumps) all the contents of the paragraphs and the tables of this Word document.
Returns:
null

Ax.ms.Word.getName

string Ax.ms.Word.getName()
Info:
Gets this document's name.
Returns:
string

Ax.ms.Word.getParagraphs

array Ax.ms.Word.getParagraphs()
Info:
Gets a list of all the paragraphs in the word document.
Returns:
array

Ax.ms.Word.getText

string Ax.ms.Word.getText()
Info:
Gets all the text of this Word document, that is, a concatenation of all the text fragments of the different parts of the document, headers included.
Returns:
string

Ax.ms.Word.load

object Ax.ms.Word.load(
	object src
)
Info:
Loads a word document from a source object.
Parameters:
src - source (blob | string[ url, base64 or filename ])
Returns:
object

Example
Copy
var document = Ax.ms.Word.load("https://bitbucket.org/deister/axional-docs-resources/raw/master/Word/template_invoice1.docx");

Ax.ms.Word.print

object Ax.ms.Word.print(
	string value
)
Info:
Creates a new text paragraph and a new run in that paragraph. A run is the lowest separation level within a word document (a paragraph may have multiple runs).
Parameters:
value - 
Returns:
object

Ax.ms.Word.scanParagraph

null Ax.ms.Word.scanParagraph(
	object element
)
Info:
Prints (dumps) all the contents of the paragraphs of this document. Used by dump().
Parameters:
element - the paragraph element (must be of type paragraph: element.getElementType() == PARAGRAPH)
Returns:
null

Ax.ms.Word.scanTable

null Ax.ms.Word.scanTable(
	object element
)
Info:
Prints (dumps) all the contents of the tables of this document. Used by dump().
Parameters:
element - the table element (must be of type paragraph: element.getElementType() == TABLE)
Returns:
null

Ax.ms.Word.setName

null Ax.ms.Word.setName(
	string name
)
Info:
Sets this document's name.
Parameters:
name - the name of the document
Returns:
null

Ax.ms.Word.toBlob

object Ax.ms.Word.toBlob()
Info:
Converts this Word document to a BLOB object.
Returns:
object

Ax.ms.Word.toEMU

smallint Ax.ms.Word.toEMU(
	double points
)
Info:
Converts points to EMUs (English Metric Unit). EMUs are used for coordinates in vector-based drawings and embedded pictures. The EMU is a virtual unit to bridge both centimeters and inches. One inch equates to 914400 EMUs and a centimeter is 360000.
Parameters:
points - points to convert
Returns:
smallint

Ax.ms.Word.update

object Ax.ms.Word.update(
	object data
)
Info:
Updates this word document with the contents of a JSON.
Parameters:
data - JSON with data
Returns:
object

3 PowerPoint

Class Ax.ms.PowerPoint


This class represents an PowerPoint SlideShow. Wrapper for Apache POI XMLSlideShow.

Constructor Summary

Method
Description
Creates a new PowerPoint instance with name "Presentation1".
JSPowerPoint(Ax.text.String name)
Creates a new PowerPoint instance with the specified name.

Method Summary

Modifier and Type
Method
Description
Creates a new slide for this PowerPoint with the defined layout.
void 
dump()
Dumps the slides and Slide Masters of this PowerPoint.
Ax.text.String 
Gets the name of this PowerPoint
getSlideMaster(int index)
When adding a new slide to a presentation, we can also choose to create it from a predefined layout.
void 
load(Object src)
Loads the PowerPoint from a defined source.
toBlob()
Converts this PowerPoint file to BLOB.

Constructor Detail

Ax.ms.PowerPoint.JSPowerPoint

Ax.ms.PowerPoint.JSPowerPoint()
Info:
Creates a new PowerPoint instance with name "Presentation1".

Ax.ms.PowerPoint.JSPowerPoint

Ax.ms.PowerPoint.JSPowerPoint(
	string name
						)
Info:
Creates a new PowerPoint instance with the specified name.
Parameters:
name - name of the PowerPoint

Example
Copy
var ppt = new Ax.ms.PowerPoint("Presentation1.pptx");

Method Detail

Ax.ms.PowerPoint.createSlide

object Ax.ms.PowerPoint.createSlide(
	object layout
)
Info:
Creates a new slide for this PowerPoint with the defined layout.
Parameters:
layout - the slide layout
Returns:
object

Ax.ms.PowerPoint.dump

null Ax.ms.PowerPoint.dump()
Info:
Dumps the slides and Slide Masters of this PowerPoint.
Returns:
null

Ax.ms.PowerPoint.getName

string Ax.ms.PowerPoint.getName()
Info:
Gets the name of this PowerPoint
Returns:
string

Ax.ms.PowerPoint.getSlideMaster

object Ax.ms.PowerPoint.getSlideMaster(
	smallint index
)
Info:
When adding a new slide to a presentation, we can also choose to create it from a predefined layout. To achieve this, we first have to retrieve the Slide Master that holds layouts (the first one (0) is the default master):
Parameters:
index - index of the Slide Master
Returns:
object

Ax.ms.PowerPoint.load

null Ax.ms.PowerPoint.load(
	object src
)
Info:
Loads the PowerPoint from a defined source.
Parameters:
src - source (blob | string[ url, base64 or filename ])
Returns:
null

Example
Copy
var ppt = new Ax.ms.PowerPoint();
 ppt.load("https://bitbucket.org/deister/axional-docs-resources/raw/master/PPT/TestPPTDashboard.pptx");

Ax.ms.PowerPoint.toBlob

object Ax.ms.PowerPoint.toBlob()
Info:
Converts this PowerPoint file to BLOB.
Returns:
object