iLogic export specified sheets to DWF
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Dear all,
How can i export only sheet 1 and sheet 3 (sheet 2 excluded) to DWF via iLogic?
Here is my code now
'------------------------------start of iLogic------------------------------
'----------rule 2, if rule 1 is ture ----------
'this rule outputs all drawing sheets to dwf, 3D models of first sheet included
path_and_name = ThisDoc.PathAndFileName(False)
DWFAddIn = ThisApplication.ApplicationAddIns.ItemById("{0AC6FD95-2F4D-42CE-8BE0-8AEA580399E4}")
oDocument = ThisApplication.ActiveDocument
oContext = ThisApplication.TransientObjects.CreateTranslationContext
oContext.Type = IOMechanismEnum.kFileBrowseIOMechanism
oOptions = ThisApplication.TransientObjects.CreateNameValueMap
oDataMedium = ThisApplication.TransientObjects.CreateDataMedium
'set the DWF publish options
If DWFAddIn.HasSaveCopyAsOptions(oDataMedium, oContext, oOptions) Then
oOptions.Value("Launch_Viewer") = launchviewer
oOptions.Value("Publish_All_Component_Props") = 1
oOptions.Value("Publish_All_Physical_Props") = 1
oOptions.Value("Password") = 0
oOptions.Value("Publish_3D_Models") = 0
If TypeOf oDocument Is DrawingDocument Then
Dim oSheets As NameValueMap
oSheets = ThisApplication.TransientObjects.CreateNameValueMap
oOptions.Value("Publish_Mode") = DWFPublishModeEnum.kCustomDWFPublish
oOptions.Value("Publish_All_Sheets") = 0
End If
End If
oDataMedium.FileName = path_and_name & "-IDW" & ".dwf"
Call DWFAddIn.SaveCopyAs(oDocument, oContext, oOptions, oDataMedium)
'------------------------------end of rule 2------------------------------
'------------------------------end of iLogic------------------------------