Author Topic: How to get layer locked ..  (Read 9366 times)

0 Members and 1 Guest are viewing this topic.

LE

  • Guest
Re: How to get layer locked ..
« Reply #15 on: October 26, 2005, 06:40:30 PM »
in the same way....

is this correct to getting the printable value..? :?

(cdr (assoc 290 (tblsearch "layer" (cdr (assoc 8 (entget ename))))))

??

Nope....

Use:

(tblobjname "layer" layer_name)


Kerry

  • Mesozoic relic
  • Seagull
  • Posts: 11654
  • class keyThumper<T>:ILazy<T>
Re: How to get layer locked ..
« Reply #16 on: October 26, 2005, 07:01:05 PM »
or you could use ActiveX ..

.. which means you can deal directly with the Object Model.

Try, and study, this ; one line at a time.
Code: [Select]
(setq ename (car (entsel)))




(vlax-dump-object (vlax-ename->vla-object ename) T)




(setq oLayer
       (vla-item
         (vla-get-layers (vla-get-activedocument (vlax-get-acad-object)))
         (cdr (assoc 8 (entget ename)))
       )
)




(setq plottable (vla-get-plottable oLayer))





(vlax-dump-object oLayer T)
kdub, kdub_nz in other timelines.
Perfection is not optional.
Everything will work just as you expect it to, unless your expectations are incorrect.
Discipline: None at all.

Andrea

  • Water Moccasin
  • Posts: 2372
Re: How to get layer locked ..
« Reply #17 on: October 26, 2005, 08:23:24 PM »
LE !!??

tblobjname  !!??

First time I see this function !!?  :?

so I presume this will be the code line ?

(cdr (assoc 290 (entget (tblobjname "layer" (cdr (assoc 8 (entget ename)))))))

thank you.
__________

Kerry !?

Your code seem interesting too..
but I have tried to use some VLAX function and i had
bad result...maybe I don't know how really it work..
need to make more tests and try to understand how it work.

In fact I had some PC who won't accept converting VLAX object.
same drawing, same PC configuration... :|  so I was lost..

If you have, or if anyone have any website who can refer me to lurn more about VLAX function
I'll put in my Favorites...
__________


thanks you guys...I do not know really where you are to go to learn all that ....but thanks.
Keep smile...

Dent Cermak

  • Guest
Re: How to get layer locked ..
« Reply #18 on: October 26, 2005, 08:37:59 PM »
Andrea, it's not stupid, just basic.
It scares me a little that someone who produces commercial software asks a question like this.
It shouldn't. Andrea is getting into an area where he hasn't gone before and to deride him is just plain bad manners.You and MP should be ashamed of yourselves. I am proud that you two know it all, but y'all are the exceptions here and not the rule. Many of us don't know diddly squat about programming, but we are trying to learn. When we stumble, implying that it's a sign of ignorance is just not right. Can either of you go on an Italian AUG site and convey your questions in that language? I think not. I admire Andrea for all he has accomplished and you attitude towards his question makes me want to hurl!
Don't look down on someone until you have walked a mile in his shoes or have out done him in equal circumstances. Anything else is dispicable.
This site was established to teach and help in the AutoCad environment. To be helpful and courteous to all comers. For the #2 guy on this site to forget that is truly shameful. Remember what Thumper said his mama taught him to say in the movie "Bambi"? IF YOU CAN'T SAY SOMETHING NICE, DON'T SAY NOTHING AT ALL". Very wise little bunny. Let's learn from him, otay?
And too, remember, it's not WHAT you say, it's HOW you say it. There are several people that have emailed me saying that they are afraid to post questions here because someone may jump on them for asking a stupid question. That needs to stop right now. Engage brain before putting mouth into motion.

<slinks down off of soap box>

Kerry

  • Mesozoic relic
  • Seagull
  • Posts: 11654
  • class keyThumper<T>:ILazy<T>
Re: How to get layer locked ..
« Reply #19 on: October 26, 2005, 09:08:18 PM »
Dent.

I have never treated anyone here with anything but respect. Nor have I ever suggested that someone was stupid, or that their questions were anything other than deserving. If you or anyone else expects me to refrain from making comments that I consider relevant to a thread then that can be easily resolved.

Up untill now I have refrained from making any social or political comment on any of the posts in this thread. Please dont get me started.

Frankly, the last thing I need or deserve is a lesson in manners from a cartoon character.

I got a laugh from your comment that I know it all. I go through the same problems as most others to get my code to do what I want.


Regards
Kerry
kdub, kdub_nz in other timelines.
Perfection is not optional.
Everything will work just as you expect it to, unless your expectations are incorrect.
Discipline: None at all.

Andrea

  • Water Moccasin
  • Posts: 2372
Re: How to get layer locked ..
« Reply #20 on: October 26, 2005, 09:24:45 PM »
Dent,

Thanks, I appreciate your support.

Kerry and LE are a good programmers, like many other..
the last comment was forgot. Please let turn the page..
tighten the hand and work together to develop utilities worthy of us.

.  <- Final point  :wink:

__________

Hey you guys..!!
When i have finished with my new program...i'll put for free download on my new website.
I think you will be impressed....( I hope)
 :lmao:
Keep smile...

Dent Cermak

  • Guest
Re: How to get layer locked ..
« Reply #21 on: October 26, 2005, 09:35:18 PM »
True Andrea. Keep the questions coming.
Kerry, as I stated, it's not WHAT you say, but HOW you say it. Contrary to your response, the QUOTED statemnent was insulting.
My Avatar is a cartoon character. I am not. Again another insulting statement. You do need a lesson in manners my man because your statements erase your response.
I don't program. I am from Mississippi. That does not mean that I am a cartoon character. Nor does it mean that my IQ is that of a Lily Pad.

Kerry

  • Mesozoic relic
  • Seagull
  • Posts: 11654
  • class keyThumper<T>:ILazy<T>
Re: How to get layer locked ..
« Reply #22 on: October 26, 2005, 09:42:46 PM »
Quote
My Avatar is a cartoon character. I am not. Again another insulting statement

and BAMBI is what. ? or Thumper, whatever character you were using to convey your moral message ?

I think you are protesting a little too loudly.

The quoted statement is not insulting. Nothing you can say will convince me otherwise.

Dent I know you are not a programmer. I checked your posts for code content before I responded.  I wonder what gives you the insight to judge my comments validity in the context it was used.
« Last Edit: October 26, 2005, 09:54:21 PM by Kerry Brown »
kdub, kdub_nz in other timelines.
Perfection is not optional.
Everything will work just as you expect it to, unless your expectations are incorrect.
Discipline: None at all.

Dent Cermak

  • Guest
Re: How to get layer locked ..
« Reply #23 on: October 26, 2005, 10:20:50 PM »
Age, experience and a subtle sense of grace.....all which you lack. :lmao:
I never insulted your intelligence.....as you did mine.....I just pointed out that you were being unnecessarily rude.
The use of Bambi characters was to point out lessons that you should have learned as a child.
I'm sorry, but I have never been able to take people who display a superiority complex through rudeness.
 Perhaps it's part of my Southern upbringing. Down here rudeness is unacceptable. In other parts of the country it is a way of life.

Kerry

  • Mesozoic relic
  • Seagull
  • Posts: 11654
  • class keyThumper<T>:ILazy<T>
Re: How to get layer locked ..
« Reply #24 on: October 26, 2005, 10:23:19 PM »
Out of respect for Mark, I will not follow this discussion down the road you are leading it.

kdub, kdub_nz in other timelines.
Perfection is not optional.
Everything will work just as you expect it to, unless your expectations are incorrect.
Discipline: None at all.

MP

  • Seagull
  • Posts: 17750
  • Have thousands of dwgs to process? Contact me.
Re: How to get layer locked ..
« Reply #25 on: October 26, 2005, 11:43:55 PM »
Quote from: Dent
... and furthermore ...

It's very simple. When one becomes the very public author of commercial software there is an instant assumption of knowledge and expertise. I'm sorry, but that just goes with the territory.

It's analogous to someone setting up shop as a doctor. There are base expectations of ability, experience and fundamental know how because the doctor sign has been put up.

Now if the doctor reveals he doesn't know how to take a pulse you are going to be surprised no matter how much you like the good doctor and wonder how he could have set up shop without that fundamental skill.

More over, there would be a level of concern for those being serviced by said doctor.

Even if the good doctor does a mighty fine job as a speech therapist.

Nothing more, nothing less.

Now you can froth and twist this into something more than this if you wish but it won't change the fundamental facts.

Coda -- Imagine for a moment someone that marketed and sold services as an expert cartographer and then asked the question "what is a prime meridian?"

Please tell me at length how you wouldn't find that incredulous.
« Last Edit: October 27, 2005, 12:02:20 AM by MP »
Engineering Technologist • CAD Automation Practitioner
Automation ▸ Design ▸ Drafting ▸ Document Control ▸ Client
cadanalyst@gmail.comhttp://cadanalyst.slack.comhttp://linkedin.com/in/cadanalyst

hudster

  • Gator
  • Posts: 2848
Re: How to get layer locked ..
« Reply #26 on: October 27, 2005, 04:17:42 AM »
This is the first time on this site I have ever seen anyone having a go at another user, and frankly I'm a little saddened by it.
I like this site because it's not pretentious.

As I was told by my father "Manners cost nothing.  If you treat people the way you want to be treated, then you'll get along fine".

So come on guys, don't fight.
Now you two kiss and make up or it's early to bed for both of you.
Revit BDS 2017, 2016, 2015, 2014, AutoCAD 2017, 2016, Navisworks 2017, 2016, BIM360 Glue

Mark

  • Custom Title
  • Seagull
  • Posts: 28753
Re: How to get layer locked ..
« Reply #27 on: October 27, 2005, 06:57:24 AM »
Moved to the correct forum.
TheSwamp.org  (serving the CAD community since 2003)

Dent Cermak

  • Guest
Re: How to get layer locked ..
« Reply #28 on: October 27, 2005, 09:29:39 AM »
Coda -- Imagine for a moment someone that marketed and sold services as an expert cartographer and then asked the question "what is a prime meridian?"

Please tell me at length how you wouldn't find that incredulous.

I hit that everyday. I cannot believe that AutoCad refuses to acknowledge that there is no such thing as MAJOR and Minor contours. I find it bemusing that they do not know what a depression contour is and what to do with it. Intergraph does. But with all of that I have never publicly cast dispersions on their abilities. That's just not right. If you thus doubt the validity of some software, don't buy it. Casting stones in a public forum is a whole nuther matter. It's like walking up to me and saying, "God, you're fat!". The statement is true, but it's not nice to say that.
Now, these are my final words on this issue. I just think we need to treat people with the dignity they deserve and realize that many of us here don't have a clue  when it comes to code. That does not make us bad people. That does not make us ignorant or inferior. We are here to learn. It's hard to learn when the response is "I can't BELIEVE you asked that!"
I have a boss at work that finds it odd that I do not know how to do superelevated curves, or blue top comps. I have to remind him that I am a cartographer,not a civil engineer. Everyone has their area. Some more than others. The idea is to be helpful and treat people as we would like to be treated. If you feel that someone may be- in your opinion- incompetent, then you have the right to feel that way. I just don't think you then have the right to mock them.

MP

  • Seagull
  • Posts: 17750
  • Have thousands of dwgs to process? Contact me.
Re: How to get layer locked ..
« Reply #29 on: October 27, 2005, 09:35:40 AM »
I just think we need to treat people with the dignity they deserve.

Agreed. Let's move forward on that note.
Engineering Technologist • CAD Automation Practitioner
Automation ▸ Design ▸ Drafting ▸ Document Control ▸ Client
cadanalyst@gmail.comhttp://cadanalyst.slack.comhttp://linkedin.com/in/cadanalyst