Lars1978
Mechanical
- Dec 30, 2015
- 327
Hi All,
I've got a journal containing the lines below:
My question'; where Can I specifiy the PDF output (I'd like it to bee single line (0,08mm) this gives more detail.
Dim i As Integer = 0
For Each sheet As Drawings.DrawingSheet In theSession.Parts.Display.DrawingSheets
'msgbox (sheet.name)
i = i + 1
'the pdf export uses 'append file', if we are on sheet 1 make sure the user wants to overwrite
'if the drawing is multisheet, don't ask on subsequent sheets
If i = 1 Then
If IO.File.Exists(pdfFile) Then
Dim rspFileExists As System.Windows.Forms.DialogResult
rspFileExists = System.Windows.Forms.MessageBox.Show("The file: '" & pdfFile & "' already exists; overwrite?", "Overwrite file?", System.Windows.Forms.MessageBoxButtons.YesNo, System.Windows.Forms.MessageBoxIcon.Question)
If rspFileExists = System.Windows.Forms.DialogResult.Yes Then
Try
IO.File.Delete(pdfFile)
Catch ex As Exception
System.Windows.Forms.MessageBox.Show(ex.Message & vbCrLf & "Journal exiting", "Error", System.Windows.Forms.MessageBoxButtons.OK, System.Windows.Forms.MessageBoxIcon.Error)
Exit Sub
End Try
Else
'user chose not to overwrite file
'msgbox("journal exiting", vbokonly)
Exit Sub
End If
End If
End If
Try
ExportPDF(sheet, pdfFile, partUnits)
Catch ex As Exception
MsgBox("Error occurred in PDF export" & vbCrLf & ex.Message & vbCrLf & "journal exiting", vbCritical + vbOKOnly)
Exit Sub
End Try
Next
Lars
NX12.0.2.9 native
Solid Edge ST10
Inventor
I've got a journal containing the lines below:
My question'; where Can I specifiy the PDF output (I'd like it to bee single line (0,08mm) this gives more detail.
Dim i As Integer = 0
For Each sheet As Drawings.DrawingSheet In theSession.Parts.Display.DrawingSheets
'msgbox (sheet.name)
i = i + 1
'the pdf export uses 'append file', if we are on sheet 1 make sure the user wants to overwrite
'if the drawing is multisheet, don't ask on subsequent sheets
If i = 1 Then
If IO.File.Exists(pdfFile) Then
Dim rspFileExists As System.Windows.Forms.DialogResult
rspFileExists = System.Windows.Forms.MessageBox.Show("The file: '" & pdfFile & "' already exists; overwrite?", "Overwrite file?", System.Windows.Forms.MessageBoxButtons.YesNo, System.Windows.Forms.MessageBoxIcon.Question)
If rspFileExists = System.Windows.Forms.DialogResult.Yes Then
Try
IO.File.Delete(pdfFile)
Catch ex As Exception
System.Windows.Forms.MessageBox.Show(ex.Message & vbCrLf & "Journal exiting", "Error", System.Windows.Forms.MessageBoxButtons.OK, System.Windows.Forms.MessageBoxIcon.Error)
Exit Sub
End Try
Else
'user chose not to overwrite file
'msgbox("journal exiting", vbokonly)
Exit Sub
End If
End If
End If
Try
ExportPDF(sheet, pdfFile, partUnits)
Catch ex As Exception
MsgBox("Error occurred in PDF export" & vbCrLf & ex.Message & vbCrLf & "journal exiting", vbCritical + vbOKOnly)
Exit Sub
End Try
Next
Lars
NX12.0.2.9 native
Solid Edge ST10
Inventor