Save as PDF locks up SolidWorks

Discussion in 'SolidWorks' started by Richard Doyle, Oct 31, 2003.

  1. Must be the Halloween spooks working early.

    All of the sudden (no system changes) my drawings are getting clipped when I
    print to an HP LaserJet 5000. And, on top of that, saving to PDF is locking
    up SolidWorks.

    I rebooted the computer, print problems remain. Reinstalled the printer to
    no avail.

    I was able to generate one PDF after the rebooot, but subsequent saveas's
    lock it up again.

    Anyone?

    Richard
     
    Richard Doyle, Oct 31, 2003
    #1
  2. What version of SW. Have you used SaveAs PDF before today with no problems.
    I wrote a little macro to saveas PDF in the same folder. Maybe skipping the
    dialog will save you the trouble. If you have "." in your Part names other
    that before ".SLDDRW".

    This saves the .PDF with the same name as the drawing title in the same
    directory
    It closes each drawing without saving changes after saving.
    (it also closes any part or assembly that is opened without saving changes)
    modify it as you will

    Corey Scheich

    Dim swApp As SldWorks.SldWorks
    Dim Part As SldWorks.ModelDoc2
    Dim AsDwgDoc As SldWorks.DrawingDoc
    Dim boolstatus As Boolean
    Dim longstatus As Long
    Dim Annotation As Object
    Dim Gtol As Object
    Dim DatumTag As Object
    Dim FeatureData As Object
    Dim Feature As Object
    Dim Component As Object
    Dim PartName() As String
    Dim MyView As Feature
    Dim ThisSheet As SldWorks.Sheet


    Public Enum swDocumentTypes_e
    swDocNONE = 0 ' Used to be TYPE_NONE
    swDocPART = 1 ' Used to be TYPE_PART
    swDocASSEMBLY = 2 ' Used to be TYPE_ASSEMBLY
    swDocDRAWING = 3 ' Used to be TYPE_DRAWING
    swDocSDM = 4 ' Solid data manager.
    End Enum

    Sub main()

    Set swApp = Application.SldWorks
    Set Part = swApp.ActiveDoc
    While Not Part Is Nothing
    If Part.GetType = swDocDRAWING Then
    Set AsDwgDoc = Part

    PartName = Split(Part.GetPathName, ".", -1, vbTextCompare)

    Set ThisSheet = AsDwgDoc.GetCurrentSheet

    Part.Extension.SelectByID ThisSheet.GetName, "SHEET", 0.025,
    0.025, 0.025, False, 1, Nothing
    AsDwgDoc.EditSketch
    AsDwgDoc.ClearSelection
    Part.ViewZoomtofit2
    Part.SaveAs2 (PartName(0)) & ".pdf", 0, True, True
    End If
    swApp.QuitDoc (Part.GetTitle)
    On Error Resume Next
    Set Part = swApp.ActiveDoc
    Wend
    End Sub
     
    Corey Scheich, Oct 31, 2003
    #2
  3. Good luck with IT!!! =)

    hope all goes well

    Corey
     
    Corey Scheich, Oct 31, 2003
    #3
  4. Thanks Corey.

    I fixed the problem by removing "Save to PDF" from my add-ins, then deleting
    the Bluebeam "printer" from my printers folder. I "added in" the add-in, and
    now all is well. I think there is a problem with another printer on my
    system. Seems that IT removed a printer I had connected to from the server,
    replaced it, and now I cannot delete it from my printer folder. I get an
    error whenever I select the printer to remove it and it closes explorer.exe.
    I reinstalled another printer from the network and now the problems are
    showing up. They can't (or won't) fix it, and I'm stuck looking for ways to
    print to my HP again. I don't believe it to be a SolidWorks problem anymore,
    although I can print the PDF files to the new printer just fine. Settings,
    settings, settings...just what I wanted to fool with on a Friday.

    Richard
     
    Richard Doyle, Oct 31, 2003
    #4
  5. Richard Doyle

    Mark Guest

    I also have the problem that "Save as PDF" from drawings locks up
    Solidworks. It happens totally at random and is not document-specific.

    Typically, I can save two or three PDF's and then have the lock-up.
    However it also sometimes happens on the first saveas after a reboot.
    I have tried:
    - deleting the Bluebeam printer and letting the add-in re-install it
    - un-installing and re-installing solidworks 2003 and 2004
    - testing two different systems (both are decent Workstations with
    Microsoft office Win2000Sp4, Lotus notes... nothing far from ordinary)
    - placing all files on the local hard drive and saving the PDF to the
    hard drive- same bad result.
    - increasing virtual memory to 4X RAM (1 Gig DDR RAM, Intel processor)

    None of these things worked

    Another thing that happens is that during the lock-up a file
    in the temp folder is being written and it will not stop until I close
    Solidworks with task manager or until this file is so big it fills the
    hard drive !! The file is a .ps file. that Bluebeam creates for
    temporary use,

    Does anyone know a solution for this problem? Does anyone else have
    this problem?

    This happens in SW2003sp5 and SW2004SP1 (Windows 2000sp4) on both the
    systems that use at work. The only time I have escaped this problem is
    on my home license on my home computer.

    My computer at home is not as powerful as what I have at work.. the most
    significant difference is that my home PC has winXP standard.

    Yes, I have talked to the VAR about it. I have tried what they have suggested.

    mark
     
    Mark, Nov 21, 2003
    #5
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.