Workbook BeforeXmlImport Event


Syntax
Private Sub Workbook_BeforeXmlImport(ByVal Map As XmlMap, ByVal Url As String, ByVal IsRefresh As Boolean, Cancel As Boolean)
Enter Code
End Sub

This event will run before Excel imports XML data into or refreshes XML data within this specific workbook.

Required Parameters
Map
The map parameter returns the map that is being imported or refreshed as an XMLMap object.  This parameter can be used to manipulate the XML map object and its properties.

Url
The url parameter returns address path of the XML map is saved as a string. Assigning a value to this parameter will tell Excel that is where the XML file that contains XML data is located.

IsRefresh
The isRefresh parameter will return a value of True if the XML map is being refreshed and a value of False if the XML map is being imported.

Cancel
The cancel parameter is original set to False when the event begins. If the cancel parameter is set to value of True then the workbook will not import or refresh the XML map.