odbx help
CADForums.net Forum Index CADForums.net
Discussion of AutoCAD and other CAD software.
 
 FAQFAQ   MemberlistMemberlist     RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 
Google
 
Web cadforums.net
odbx help

 
Post new topic   Reply to topic    CADForums.net Forum Index -> Customization
Author Message
BTO
Guest





Posted: Fri Dec 17, 2004 8:35 pm    Post subject: odbx help Reply with quote

hello,
After having read much here, I write my first lisps with odbx, this kind of
little routine :

(defun c:odbx_freeze_layers ( / File1 odbx )
(setq File1 (getfiled "Selection du fichier" "C:/traitement/" "dwg" 0 ))
(setq odbx (vla-getinterfaceobject (vlax-get-acad-object)
"ObjectDBX.AxDbDocument.16"))
(vla-open odbx File1 )
(princ "\nCalques gelés :")
(vlax-for layer (vla-get-Layers odbx )
(vla-put-Freeze layer :vlax-true)
(princ (strcat "\n" (vla-get-name layer)))
)
(vla-saveas odbx File1 )
(vlax-release-object odbx)
)

but i can't find any answer about how to modify a variable (I sought with
google, google group ect, here...).

with vl I use someting like :

(vl-load-com)
(setq thisdrawing (vla-get-activedocument (vlax-get-acad-object)))
(vla-GetVariable thisdrawing "fillmode")
(vla-SetVariable thisdrawing "fillmode" 0 )

or

(vla-get-name (vla-get-activelayer thisdrawing ))

but :
(vla-get-name (vla-get-activelayer odbx )) doesn't work and everything that
needs (vla-get-activedocument... too


second point, I tried to use AuditInfo method, but without any success via
odbx because i need (vla-get-activedocument.
(vla-AuditInfo thisdrawing :vlax-true) works

Any help is welcome.
thx,

My english writing is bad, but i will understand you

Bruno Toniutti.

Back to top
Jeff Mishler
Guest





Posted: Fri Dec 17, 2004 10:05 pm    Post subject: Re: odbx help Reply with quote

That is one of the limitations of ODBX, System variables are not accessible.

--
Jeff
check out www.cadvault.com
"BTO" <NOSPAMacad@berim.fr> wrote in message news:41c2fe4b$1_1@newsprd01...
Quote:
hello,
After having read much here, I write my first lisps with odbx, this kind
of
little routine :

(defun c:odbx_freeze_layers ( / File1 odbx )
(setq File1 (getfiled "Selection du fichier" "C:/traitement/" "dwg" 0 ))
(setq odbx (vla-getinterfaceobject (vlax-get-acad-object)
"ObjectDBX.AxDbDocument.16"))
(vla-open odbx File1 )
(princ "\nCalques gelés :")
(vlax-for layer (vla-get-Layers odbx )
(vla-put-Freeze layer :vlax-true)
(princ (strcat "\n" (vla-get-name layer)))
)
(vla-saveas odbx File1 )
(vlax-release-object odbx)
)

but i can't find any answer about how to modify a variable (I sought with
google, google group ect, here...).

with vl I use someting like :

(vl-load-com)
(setq thisdrawing (vla-get-activedocument (vlax-get-acad-object)))
(vla-GetVariable thisdrawing "fillmode")
(vla-SetVariable thisdrawing "fillmode" 0 )

or

(vla-get-name (vla-get-activelayer thisdrawing ))

but :
(vla-get-name (vla-get-activelayer odbx )) doesn't work and everything
that
needs (vla-get-activedocument... too


second point, I tried to use AuditInfo method, but without any success via
odbx because i need (vla-get-activedocument.
(vla-AuditInfo thisdrawing :vlax-true) works

Any help is welcome.
thx,

My english writing is bad, but i will understand you

Bruno Toniutti.


Back to top
BTO
Guest





Posted: Mon Dec 20, 2004 1:44 pm    Post subject: Re: odbx help Reply with quote

Quote:
That is one of the limitations of ODBX, System variables are not
accessible.


thanks you Jeff,
good explanation why i found nothing about it

Bruno Toniutti

Back to top
 
Post new topic   Reply to topic    CADForums.net Forum Index -> Customization All times are GMT
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum




Windows Server DSP VoIP Electronics New Topics
Powered by phpBB