See the top rated post in this thread. Click here

Page 3 of 5 FirstFirst 12345 LastLast
Results 21 to 30 of 46

Thread: Page Setup Manager

  1. #21
    AUGI Director scott.wilcox's Avatar
    Join Date
    2015-11
    Location
    Edmonton, Alberta
    Posts
    990
    Login to Give a bone
    0

    Default Re: Page Setup Manager

    I am still having issues.

    Layouts are uniquely named.
    Page setups exist in the drawing.
    Layouts are mapped to page setups.

    Still getting "Nothing selected to change." message
    Even tried it with multiple layout tabs selected.
    What gives? Any ideas?

  2. #22
    Certifiable AUGI Addict
    Join Date
    2015-11
    Location
    Jo'burg SA
    Posts
    4,512
    Login to Give a bone
    0

    Default Re: Page Setup Manager

    There must be something else going on then, it works fine for me (see attached). Maybe it's incompatible with your version of ACad? The sample shows Vanilla 2008.
    Attached Images Attached Images

  3. #23
    AUGI Director scott.wilcox's Avatar
    Join Date
    2015-11
    Location
    Edmonton, Alberta
    Posts
    990
    Login to Give a bone
    0

    Default Re: Page Setup Manager

    OK, it's working!
    The files were not in the support path, despite my earlier claims. Sorry for the inconvenience, and thanks for the awesome file!

  4. #24
    Certifiable AUGI Addict
    Join Date
    2015-11
    Location
    Jo'burg SA
    Posts
    4,512
    Login to Give a bone
    0

    Default Re: Page Setup Manager

    Quote Originally Posted by scott.wilcox View Post
    OK, it's working!
    The files were not in the support path, despite my earlier claims. Sorry for the inconvenience, and thanks for the awesome file!
    No prob ... you're welcome

  5. #25
    Active Member
    Join Date
    2009-06
    Location
    Toowoomba, QLD, Aus
    Posts
    74
    Login to Give a bone
    0

    Default Re: Page Setup Manager

    This LSP is great, I have been looking for something like this for a while.
    Is it possible to launch this from a tool palette, or even better, I already have a tool palette icon that inserts the commonly used page setups, is it possible to add this to the command string in my existing tool palette that will set "KM_A1-A3" current.
    The palette command string currently looks like this
    (command "-psetupin" "KM.dwt" "KM_A1-A3,KM_A1_DRAFT,KM_A1_final,KM_PDF")
    Note: this works only with Expert system variable set to 3.

  6. #26
    Active Member
    Join Date
    2009-06
    Location
    Toowoomba, QLD, Aus
    Posts
    74
    Login to Give a bone
    0

    Default Re: Page Setup Manager

    never mind, sorted that out
    ^c^c-psetupin;km.dwt;KM_A1-A3,KM_A1_DRAFT,KM_A1_final,KM_PDF;-MPAGESETUP;*;KM_A1-A3;

  7. #27
    100 Club
    Join Date
    2005-06
    Location
    Atlanta
    Posts
    118
    Login to Give a bone
    0

    Default Re: Page Setup Manager

    Just saved and tested the LayoutTools.lsp, and it works! This has been a thorn in my side for a long time. Finally had it somewhat solved with the DWGTrueView fix, which seems to have stopped working.

    Page setups are added to drawings, only hitch is that with 2013, it does not set a pagesetup to "current", and in the dialog pictured above, it looks like it has done so. Am I missing a step somewhere?

    I also do not get any dialogs to select tabs to apply it to, but it works when I select tabs ahead of running the LSP. Is this how it is supposed to work?

    PageSetup.JPG

  8. #28
    Administrator BlackBox's Avatar
    Join Date
    2009-11
    Posts
    5,714
    Login to Give a bone
    0

    Default Re: Page Setup Manager

    Zombies!


    I don't recall if LISP can set a page setup current, without a call to the -PLOT Command, which precludes the ability to batch process a directory of drawings via ObjectDBX. This is possible via .NET API however. I've been toying with the idea of adding a plug-in that can do this, but haven't made the time... Perhaps if others would also benefit, I'd make some time in the coming weeks when possible.
    "How we think determines what we do, and what we do determines what we get."

    Sincpac C3D ~ Autodesk Exchange Apps

    Computer Specs:
    Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000

  9. #29
    Administrator BlackBox's Avatar
    Join Date
    2009-11
    Posts
    5,714
    Login to Give a bone
    0

    Default Re: Page Setup Manager

    Quote Originally Posted by Julesagain View Post
    ... it does not set a pagesetup to "current"
    Quote Originally Posted by BlackBox View Post
    I don't recall if LISP can set a page setup current, without a call to the -PLOT Command, which precludes the ability to batch process a directory of drawings via ObjectDBX. This is possible via .NET API however. I've been toying with the idea of adding a plug-in that can do this, but haven't made the time... Perhaps if others would also benefit, I'd make some time in the coming weeks when possible.
    Here's a temporary work around for 2012 and older... I know... You're asking about 2013, but I do not have the ObjectARX 2013/2014 SDK installed at work, only at home sadly. I consider this to be a' temporary' work around, as it is but a simple CommandMethod Method (read a Command) at this time... Meaning for this to work one would need to invoke the "AcPageSetup" Command.

    My intention is to make this available as a LispFunction Method (read a LISP function) so one can employ this functionality in other LISP routines, and offer an optional enhanced Command to batch process a directory of Drawings.

    In any event, here's the best I could with part of my lunch break:

    Code:
    using Autodesk.AutoCAD.ApplicationServices;
    using Autodesk.AutoCAD.DatabaseServices;
    using Autodesk.AutoCAD.EditorInput;
    using Autodesk.AutoCAD.Runtime;
    
    using acApp = Autodesk.AutoCAD.ApplicationServices.Application;
    
    [assembly: CommandClass(typeof(AUGI.Sample.PageSetup.Commands))]
    
    namespace AUGI.Sample.PageSetup
    {
        public class Commands
        {
            [CommandMethod("AUGI", "AcPageSetup", CommandFlags.Session)]
            public void AcPageSetup()
            {
                Document doc = acApp.DocumentManager.MdiActiveDocument;
    
                Database db = doc.Database;
    
                string pageSetupName = "YourPageSetupName";
    
                using (DocumentLock docLock = doc.LockDocument())
                {
                    using (Transaction trans = 
                        db.TransactionManager.StartOpenCloseTransaction())
                    {
                        LayoutManager acLayMan = LayoutManager.Current;
    
                        Layout oLayout = trans.GetObject(
                            acLayMan.GetLayoutId(acLayMan.CurrentLayout),
                            OpenMode.ForRead) as Layout;
    
                        if (oLayout != null)
                        {
                            DBDictionary acPlotSettings =
                                trans.GetObject(db.PlotSettingsDictionaryId,
                                OpenMode.ForRead) as DBDictionary;
    
                            if (acPlotSettings.Contains(pageSetupName))
                            {
                                PlotSettings ps =
                                    (PlotSettings)trans.GetObject(
                                        acPlotSettings.GetAt(pageSetupName), OpenMode.ForRead);
    
                                oLayout.UpgradeOpen();
    
                                oLayout.CopyFrom(ps);
    
                                trans.Commit();
                            }
    
                            else
                                doc.Editor.WriteMessage("\n** Page setup not found ** ");
                        }
                    }
    
                    doc.Editor.Regen();
                }
            }
    
        }
    
    }

    I'll post the assemblies (the .dll, read compiled code) when I am able to build the 2013 compatible project at my soonest convenience.
    Last edited by BlackBox; 2013-03-20 at 09:53 PM. Reason: Added a 'Page Setup Not Found' error message
    "How we think determines what we do, and what we do determines what we get."

    Sincpac C3D ~ Autodesk Exchange Apps

    Computer Specs:
    Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000

  10. #30
    Administrator BlackBox's Avatar
    Join Date
    2009-11
    Posts
    5,714
    Login to Give a bone
    0

    Default Re: Page Setup Manager

    Actually, the more I think about this, it might be useful to incorporate an external settings file (.XML) (rather than hard-coding the named page setup as shown above), that can be located within a given project, as I know in my limited experience it's often necessary to have a different named page setup applied as default for different projects (i.e., different client standards, etc.)... This just might turn into a nifty little project.
    "How we think determines what we do, and what we do determines what we get."

    Sincpac C3D ~ Autodesk Exchange Apps

    Computer Specs:
    Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000

Page 3 of 5 FirstFirst 12345 LastLast

Similar Threads

  1. Page Setup Manager Dialog
    By autocad.wishlist1734 in forum AutoCAD Wish List
    Replies: 2
    Last Post: 2009-10-13, 04:53 AM
  2. page setup manager SLOW
    By cr_gixxer in forum ACA General
    Replies: 1
    Last Post: 2009-05-08, 10:05 PM
  3. Enhancement to Page Setup Manager
    By autocad.wishlist1734 in forum AutoCAD Wish List
    Replies: 2
    Last Post: 2006-02-13, 05:08 PM
  4. Add Plot Stamp to Page Setup Manager
    By autocad.wishlist1734 in forum AutoCAD Wish List
    Replies: 1
    Last Post: 2006-01-15, 05:25 AM
  5. Page Setup Manager
    By ejohnson.73328 in forum AutoCAD General
    Replies: 4
    Last Post: 2004-08-27, 02:13 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •