Hello everyone
I read the content of this forum with enthusiasm, which is why I thought that I was in good hands with my problem here.
Quick info in advance: I'm a macro newbie!
I use SoWo 2021 SP5.1 Standard and have included a macro to reload the sheet format. This works well, except for the leaf scale. The macro always resets him to 1:1, although he e.g. 5:1.
What should the macro look like in order to « exclude » the sheet scale?
Can someone help me with this?
I thank you in advance for your effort :-)
tippe oder füge den Code hier einDim swApp As Object
Dim Part As Object
Dim boolstatus As Boolean
Dim longstatus As Long, longwarnings As Long
Sub main()
Set swApp = Application.SldWorks
Set Part = swApp.ActiveDoc
boolstatus = Part.Extension.SelectByID2("Blatt1", "SHEET", 0.280273244100153, 0.269057755102041, 0, False, 0, Nothing, 0)
boolstatus = Part.Extension.SelectByID2("Blattformat1", "SHEET", 0, 0, 0, False, 0, Nothing, 0)
boolstatus = Part.Extension.SelectByID2("Blattformat1", "SHEET", 0, 0, 0, False, 0, Nothing, 0)
Part.ClearSelection2 True
boolstatus = Part.SetupSheet5("Blatt1", 12, 12, 5, 1, True, "DIN A3, V2.slddrt", 0.42, 0.297, "Standard", False)
boolstatus = Part.SetupSheet5("Blatt1", 12, 12, 5, 1, True, "DIN A3, V2.slddrt", 0.42, 0.297, "Standard", False)
' Zoom To Fit
Part.ViewZoomtofit2
' Zoom To Fit
Part.ViewZoomtofit2
' Zoom To Fit
Part.ViewZoomtofit2
' Save
Dim swErrors As Long
Dim swWarnings As Long
boolstatus = Part.Save3(1, swErrors, swWarnings)
End Sub