I have now tried to add the attributes using vla-addattribute, but I can not get it to work. the blk above is the name of the block which is inserted fine and has name e.g Space001 . When I try and add the attributes and I use vla-addAttribute blk (height mode prompt etc) I get error - bad argument type VLA-OBJECT "Space001". If I change the blk to (vla-get-name blk) or (vla-get-block blk) I get error nil VLA-OBJECT.
How do get the vla-addattributes to use the block (blk) in the code above, I have tried every combination I can think of including (vlax-ename->vla-object but to no avail.
I have managed to get this to work in model space without attaching to a block but can not attach items to the block.
Opps my fault, I picked it up the code and then copied some more code over it without thinking. Now see my problem, I have added an odd bit of code which overwrote the block word in the code. It make sense now and works a treat.
Carbon interface has failed on the computer today. I'm not used to the sunshine its gone to my head.
Many thanks again for you prompt help. It would be ideal if I did'nt mess it up at my end.
My error indeed, I didn't realise until I had posted I had started a new thread. Must stop doing two things at once.
I had intended to feed back later on original question, I just got side tracked with some thing else.
I am finding it hard getting back into lisp after a 10 year break away from it. But I have learnd a vast amount in the last two days.
The problems I know are not big they are just bring me to a halt whilst I try and think how to get over the hurdle.
Having spent much time programming in OO and SQL its difficult get back in to the swing of lisp and some of the things that use to be second nature to me.
I hope I can contribute back to forum soon in recognition of the help I get..