TSService.MetadataChangeStart

Syntax

MetadataChangeStart: function (sender, args);

Parameters

sender. Event source.

args. Event information.

Description

The MetadataChangeStart event is fired when metadata starts changing.

Example

To execute the example, the page must contain the WorkbookBox component named workbookBox (see Example of Creating the WorkbookBox Component), service named tsService used to work with time series, and also the user must add the following code in the event handler that processes document opening:

	var wbk = workbookBox.getSource().getActiveSheet();
	var setMetadataButt = new PP.Ui.Button({
		ParentNode: document.body, //DOM parent node
		Content: "Set metadata", //text      
		Click: PP.Delegate(onClickSetMetadata)
	});
	function onClickSetMetadata() {
		//Change metadata
		tsService.setMetadata(wbk);
	}
				 
	//Add a metadata change start event handler
	tsService.MetadataChangeStart.add(function () {
		alert('Metadata load start event occurred');
	});
				 
	//Add a metadata change end event handler
	tsService.MetadataChanged.add(function () {
		alert('Metadata change end occurred');
	});

After executing the example a button named Set Metadata is placed in the HTML page. Clicking this button saves workbook metadata in the server. First a notice is shown that the metadata changing has started, next the notice on metadata changing end event.

See also:

TSService