Jump to content

Recommended Posts

Posted

Hi, i am trying to retrieve a user grid scale factor value using either autolisp or VBA. can anyone help please?

 

Thanks,

bzz.

Posted

I think yes, the same :

 

(defun c:grids ( / g )
 (setq g (getvar 'gridunit))
 (setq g
   (cond
     ((getpoint (strcat "\nSpecify new gridunit variable <" (rtos (car g)) "," (rtos (cadr g)) "> : ")))
     (g)
   )
 )
 (if (caddr g) (setq g (list (car g) (cadr g))))
 (setvar 'gridunit g)
 (princ)
)

Posted

Thanks marko_ribar and Tharwat

but gridunit sys variable specifies grid spacing for the current viewport. I am trying to get a user-defined Grid scale that is set from drawing settings window in transformation tab.

Posted

If you want to set the grid scale manually , how would you set it ?

 

I couldn't find transformation tab in the Drawing Settings Window in my Autocad 2014

Posted

on the command line I type in "editdrawingsettings" and then click on transormation tab and set the user-defined grid scale factor value

Posted
on the command line I type in "editdrawingsettings" and then click on transormation tab and set the user-defined grid scale factor value

That option might be available only in Civil cad as it is shown into your profile , can you upload a snapshot of that dialog ?

Posted

I would try with command sysvdlg and type there *grid*, and if there is sysvar for grid scale factor, then it should be simple to use (getvar "???") where ??? is that name of sysvar...

Posted

This is only available in civil3D

 

Unfortunately I do not either have or work with Civil3D but we have lots of nice guys in this forum using that Cad version and they are very helpful guys , so just wait and you should have your question answered in no time . :)

Posted

Thanks marko_ribar, unfortunatelly all the sysvariables about the grid didn't help

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...