Beginner question

 Hi,

I just started using Bricscad, and I have few beginner questions :

- Is there a shortcut to lock a windows in a Layout, instead of going in properties ?
- Why the scale doesn't change in the window when i do a right click on the scale option ? (the toolbar below)
- How can i print in JPG format. When I use print and select publishtoweb JPG, it tells me that this configuration it's not supported....

Sorry for my english, i'm a french user. But i think there are more english or americans users.

Thank you !
«1

Comments

  • First, your English is excellent!  I am on v14, so my reply may be a little outdated.

    I don't understand question #2.

    To create raster images, I sometimes just copy the screen using the "Snipping tool" that comes with windows.  But, if you want more resolution than what your monitor provides, you need to use a printer driver, that will create an image file, rather than use a physical printer.  The one I use for images is called "Paperless Printer".

    For locking viewports, I use a LISP routine, and use that to lock or unlock all viewports.  I have this LISP routine to automatically load everytime I start a document, by putting it in the "on_doc_loadl.lsp" file. Mine looks like this, but you will obviously have to make the path and file name correct for your system.
    (load "D:/Joes Data/AutoCAD Custom Stuff/Lisp/Lock or Unlock all Viewports.lsp")
    I use the command line "VPLA" "VPUA", which, to me, means "View Port Lock All" or "View Port Unlock All".  But, you can place those  same commands in a macro button if you prefer.

    The lisp routine was written by the AutoCAD/BricsCAD guru Lee Mac.  www.lee-mac.com
    But, the routine was not on his web site.  Rather, I found it on the AUGI forum.  Here it is below. I may have changed the command abbreviation, but otherwise it is as he wrote it.

    [code]; By Lee-Mac, found at the Augi forums
    ;; Lock selected or all viewport
     
    (vl-load-com)

    (princ "\n type VPL or VPU to lock or unlock selected viewports")
    (princ "\n type VPLA to Lock, or VPUA to unlock all vieports")
     
    (defun c:vpl nil
     
    (if (SSVPLock (ssget "_+.:E:S:L" '((0 . "VIEWPORT"))) :vlax-true)
     
    (princ "\n--> Viewport Locked.")
     
    )
     
    (princ)
     
    )
     
    ;; Unlock Selected Viewport
     
    (defun c:vpu nil
     
    (if (SSVPLock (ssget "_+.:E:S:L" '((0 . "VIEWPORT"))) :vlax-false)
     
    (princ "\n--> Viewport Unlocked.")
     
    )
     
    (princ)
     
    )
     
    ;; Lock All Viewports
     
    (defun c:vpla nil
     
    (SSVPLock (ssget "_X" '((0 . "VIEWPORT"))) :vlax-true)
     
    (princ "\n--> All Viewports Locked.")
     
    (princ)
     
    )
     
    ;; Unlock All Viewports
     
    (defun c:vpua nil ;; changed "VPLU" to "VPUA" to be consistant with the above function
     
    (SSVPLock (ssget "_X" '((0 . "VIEWPORT"))) :vlax-false)
     
    (princ "\n--> All Viewports UnLocked.")
     
    (princ)
     
    )
     
    (defun SSVPLock ( ss lock / i )
     
    (if ss
     
    (repeat (setq i (sslength ss))
     
    (vla-put-displaylocked (vlax-ename->vla-object (ssname ss (setq i (1- i)))) lock) t
     
    )
     
    )
     
    )[/code]

    -Joe
  • #2: The SCALE command increases or decreases the size of an entity. It normally appears in the right-click "context" menu when any scalable entity is selected. It can change the size of a viewport, and if the viewport is unlocked it will also change the viewport scale proportionally.

    I don't think there is a built-in command for just changing viewport scale, but this custom command will do it:
    [code];;; SVP = Scale ViewPort - changes the scale of a viewport, even if the viewport is locked
    (defun c:SVP (/ NotPS NoSS SF SFI ss1 N vpN ObjN)
    (defun NotPS () (prompt "\nOnly works in Paperspace. ") (exit) )
    (if (> (getvar "CVPORT") 1) (NotPS) )  ;; CVport:  Pspace=1;  Mspace=2;  Vport=2+
    (initget 7)   ; prevents Negative, Zero, or Null input
    (setq SF (getreal "Scale Factor: "))
    (setq SFI (/ 1.0 SF))
    (defun NoSS () (princ "\nNo viewport selected. ") (exit) )
    (setq ss1 (ssget '((0 . "VIEWPORT")) ) )  ; selection filtered - viewports only
    (if (not ss1) (NoSS))
    (setq N 0)
    (while (< N (sslength ss1) )
      (setq vpN (ssname ss1 N) )
      (setq ObjN (vlax-ename->vla-object vpN))
      (Vla-Put-CustomScale ObjN SFI)
      (setq N (+ N 1))
      )
    (sssetfirst nil ss1)
    )[/code]
  • #1: There is also a custom command by Theodorus Winata which locks or unlocks a particular viewport or all viewports. It's posted in another forum, at http://forums.augi.com/showthread.php?105726-Is-Lisp-the-right-tool-to-create-this-routine

  •  Thank you for your useful answer !

    It's OK for points 1 and 2

    I will now try "paperless printer" instead of publishtoweb JPG, 'cause I need a personal dimension.

    So for the lock of the viewports, there is no locker in the toolbar like Autocad ?
    Because i did'nt master lisps, so if there is no another way, I will use the properties windows.

    An other point, there is no design center likes autocad ? It was very useful for copy/paste the layouts.

    Thx ! :)
  •  The equivalent of AutoCAD's Design Center in BricsCAD is the Drawing Explorer. See the Help to learn how to use the Drawing Explorer or watch tutorial videos:
    To insert a layout from another drawing: right click the layout tab, then choose 'From Template...' and select  the source file.

  • I'm not familiar with Design Center, but it's easy to copy and paste viewports by using Ctrl-C and Ctrl-V, or CopyBase and PasteClip. And you can make a new copy of a layout by right-clicking the layout tab and selecting "Copy" (or copy a layout from another DWG file by selecting "From template....").

    Learning Lisp can be a lot of work, but it's easy to use Lisp custom commands created by other people. Just find or create a text file called "on_doc_load.lsp" in the Program Files/Bricsys/Bricscad/Support folder, and paste in the lisp code. That code will be loaded automatically every time you open a DWG file, and you can use the custom command by typing it or adding it to a menu or toolbar. You can add as many custom commands as you want. The command name is immediately after "defun c:" in the code. For my ScaleViewPort command, it's SVP. You can change the name to whatever you want and it won't affect the rest of the code.
  • ...So for the lock of the viewports, there is no locker in the toolbar like Autocad ?


    Easy enough to create a custom tool button with the command ^C^C-VPORTS;LOCK;ON;ALL;;
  •  First I will second the statement that you don't need to know LISP to use LISP.  And while I dabbled in it many years ago, I neither mastered it, nor do I retain much of it now.

    For LISP code you see on a forum.  Just copy the text and paste it into a pure text document (using Notepad or other text editor).  Then save the file with the .lsp extension.  You can load the LISP routine by using the TOOLS/LOAD APPLICATION menu, or automatically by adding the code to the on_doc_loadl.lsp file. or in the example I gave, I only added a line to have lisp load this other lisp routine.

    Learning to use these types of programs and make macros is a powerful way to increase your productivity, and eliminate some of the boring tasks involved with CAD.

    -Joe
  •  Thank for your help !

    I will try some lisp, I think it's the best way to make my work easier.

    Robt Deans, I don't understand your ^C^C-VPORTS;LOCK;ON;ALL;;  command. Is it lisp ?

    Joe, thanks for your reactivity :)

  •  The equivalent of AutoCAD's Design Center in BricsCAD is the Drawing Explorer. See the Help to learn how to use the Drawing Explorer or watch tutorial videos:
    To insert a layout from another drawing: right click the layout tab, then choose 'From Template...' and select  the source file.


    Louis, I just watched this tutorial about how to copy/paste my page setup, but my copy icon is grayed out. and it tells me with a right click that is impossible to copy a presentation...weird... Is there an explanation ?
  • ...I don't understand your ^C^C-VPORTS;LOCK;ON;ALL;;  command. Is it lisp ?



    No.
    Right click on you Toolbar and select "Customize".
    Look here for a tutorial on Adding Tools;
    https://www.bricsys.com/bricscad/help/es_ES/V10/UsrGui/source/02_Defining_your_preferences/02_03_Creating_custom_tools.htm
    ^C^C-VPORTS;LOCK;ON;ALL;; ultimately will be the command inserted in the appropriate field.

  • You can also use a macro to create a custom command that sets the scale of a viewport.
    This would change the scale of a pre-selected viewport to 1:100 and then lock the viewport:
    [code]Vports;Lock;Off;Mspace;Zoom;1/100xp;Pspace;Vports;Lock;On;P;;[/code]
  •  Robt, i create the custom command, but i can't find it in my work area...
    How to find it ?

    Anthony, can you explain me the full process of your tips ?

    I'm not sure I understand...

    Thx !
  • Eventually, after some research i found the solution.

    So thanks to you both of you !

    Now i'm looking for changing scale in an unlocked window. 

    Currently, the only way for me is to go out the window, select it, and change in the properties, but it's not practical...
  • Hello.

    You can build your own tools for that:
    ^C^Czoom;10xp;
    This is the setting for scale 1:100, if you use one drawingunit as one metre.
    So it´s ^C^Czoom;20xp; for 1:50 and so on.

    To create new tools just type "cui" into the commandprompt, rightclick onto an existing tool and follow the steps to create a new tool.
    See attachment.

    Having these tools you just have to click into the viewport and click onto the toolbutton you created.

    By the way: with click-and-hold the middle mouse button you can move within your viewport without loosing the scalesettings.

    Good luck.

    Sascha
    imageScreenshot_1.jpg
  •  Thanks Sacha, i succed to create that!
    But where can i find the "logo" for the scale (1:100 1:200,...etc) ?
  • But where can i find the "logo" for the scale (1:100 1:200,...etc) ?

    I think "Icon" is the English term for the small square image that you click with your mouse to start a command.

    The approach mentioned would involve you making your own macro and icon for each scale you typically use.  I typically just use "Paint" that comes with Windows.  And then set the resolution of the image to be 32x32 pixels, and use 256 colors.  Save it as a .bmp file. At 32x32 you don't have much resolution to put your text. So, you might omit the 1: part, and just put 100, 200 etc.

    When you define the macro, and put it on a toolbar, you have the option of choosing from the existing icons, or browsing to your own image.  I know it is a lot to start to learn, but this type of work will be giving you benefits for the rest of you career.  I still use macros and icons I created 20 years ago.

    Because these icons take work to create, be sure to save them to a directory that will not get overwritten when you re-install or upgrade BricsCAD.  I have a CAD Customization directory where I put all my LISP routines, Icons, custom linetypes, backups of my menu system, and backups of the personal profile.  In the case of my LISP collection, I put them in sub-directories because some of them need a PDF or other file that describes how to use it.

    -Joe
  • Hi Benjamin.

    I don´t mind giving you mine. See attachments.
    As Joe already mentioned you have to save them somewhere and then choose the path in the cui. Also see attachment.
    Just remind that the icons are not embedded. So you have to keep the icons in the place your path leads to.

    Once you open one of the icons in e.g. Photoshop you will see how they are built and you will be able to create your own.

    Again good luck.

    Sascha
    imageBem 1-200.bmp
    imageScreenshot_1.jpg
    imageBem 1-5.bmp
    imageBem 1-500.bmp
    imageBem 1-1.bmp
    imageBem 1-50.bmp
    imageBem 1-100.bmp
    imageBem 1-10.bmp
    imageBem 1-2.bmp
    imageBem 1-20.bmp
    imageBem 1-1000.bmp
  •  Perfect, a big thank to you Sascha :).

    My Bricscad become better day after day !
  •  Sascha, or someone else :),

    Maybe you have another solution to copy a layout for an other open folder?
    Because as i said, "right click the layout tab, then choose 'From Template...' and select  the source file" is not very practical...

    And in the Drawing Explorer, i can't copy/paste, cause the buttons are grayed out.
  • Hello.

    I´m not sure, if I understood how you work and how you handle layouts.
    I´m working in architecture and we need different papersizes for 3 different phases in an architectural projekt. Means for the phase "design" we need layouts in A4, A3 A2...and sometimes even portrait insteed of landscape...
    Each drawing needs to have a legend and our company logo.
    We preset around 20 different layouts so that we can be sure, that every printed drawing looks the same, no matter who of us printed it.

    There are two ways to handle these 20 layouts:

    1. You have a template drawing and set all possible layouts in there.
    Once you start Bricscad, it opens this templatedrawing as a new drawing.
    Now you already have all layouts in each drawing. Bad about this is: The drawings can become pretty big because of all the layouts and to keep your drawing clean you will have to delete all unused layouts.

    2. You make yourself a "Standards"-drawing with all your layouts. (This can also be the rootdrawing for your blocks that you might use via toolpalettes and many more.)
    Once you choose the path to this drawing via right-click on a layout this path will be saved as last path.
    So the next time you want to pick another layout you will be lead to your "Standards"-drawing automatically until you change this path.
    See attachments.

    Pretty easy.

    We work like this:
    In the Templatedrawing we have the 3 most used layouts.
    About 15 more standardlayouts we find in our Standarddrawing.

    Hope, this helps.

    Sascha
    imageScreenshot_3.jpg
    imageScreenshot_1.jpg
    imageScreenshot_4.jpg
    imageScreenshot_2.jpg
  •  Pretty accurate, thank you !

    What I want more is to do like AutoCAD.
    I explain myself :

    If I have two files open in autocad, i was able to copy/paste a layout from a drawing to the other with design center.
    If i want to do the same on Bricscad, it doesn't work because i can't use copy/paste and I don't know why. 
    I have an error message which tells me something like (unable to copy and paste layout).


    And i notice it's possible...

    I think it's more practical than using 'From Template...' and select  the source file...

    So i don't understand...

    Any suggestions ? ^^

  • Can it be, that you are working with Bricscad Classic and would need Pro?
  • You can only copy-paste page setups and not layouts (names starting and ending with '*') in the _PAGESETUP panel.
    If you want to insert layouts more efficiently you can try creating a custom tool based on the _LAYOUT command.
  • Hello Roy,

    where would I find these page setups that I can copy?
    And why do I find "Copy" and "Paste" command in the pagesetuppanel?

    Thanks,

    Sascha
  • Hi Roy,

    Same question than Sascha :)
  • In the _PAGESETUP panel there is a 'New' button... I don't need to explain the next steps I think.
    If you select a page setup that is not a layout, you can use copy-paste.
    It is possible to base multiple layouts on the same page setup. Which can be a handy feature.
  • And you can copy the Page Setup from one existing Layout to another existing Layout.
    imageCopyPageSetup.jpg
  •  If I create a new page setup, I can't choose anything in "based on", it's inactive...

    On Autocad, when i worked on wiring diagram with many folios on two different dwg, i did use designcenter to found the layout of one of my dwg, chose all and double click on, so it did copy these layouts on the active dwg. Very useful because the insertion point of the folio were the same.

    Here i think it's not possible to do that with your solution Rob and Anthony.

    Maybe the word I use are technically innapropriate 'cause I'm french user...

    Sorry, maybe my questions are obvious 
  • When you create a new page setup you can base it on an existing layout or page setup. But you cannot set a value in the 'Based on' column of the _PAGESETUP panel for a page setup. This would make little sense. But you can base a layout on either a page setup or a different layout as demonstrated by Anthony.
This discussion has been closed.