numeric user attribute

numeric user attribute

peter_goodwin
Contributor Contributor
1,274 Views
20 Replies
Message 1 of 21

numeric user attribute

peter_goodwin
Contributor
Contributor

i have an attribute in a block that prompts. i enter a number. i have a formula that points to that attribute object value and it will not compute. if i set a default value it will compute with that value but not from the entered value.

 

I feel as though i am missing something simple.

0 Likes
1,275 Views
20 Replies
Replies (20)
Message 2 of 21

ChicagoLooper
Mentor
Mentor

Sorry, your explanation is too vague. I’m sure you understand the problems you are facing but the forum cannot. You need to provide better descriptions to readers who are inexperienced using  with your block and unfamiliar with your issues. 

Use details and examples when describing your problem. Better yet, upload your block and explain the result you are expecting and result you actually getting. 

Chicagolooper

EESignature

0 Likes
Message 3 of 21

vinodkl
Mentor
Mentor

Hi,

 

If I understand your requirement correctly, I think you are trying reference one attribute value into another attribute within a block. For this you need to create a user parameter to reflect the changes. The below screencast would explain it well.

 

--------------------------------------------------------------------------------------------------------------------------
ವಿನೋದ್ ಕೆ ಎಲ್( System Design Engineer)
Likes is much appreciated if the information I have shared is helpful to you and/or others.

Please mark "Accept as Solution" if my reply resolves the issue or answers your question, to help others in the community.
--------------------------------------------------------------------------------------------------------------------------
0 Likes
Message 4 of 21

peter_goodwin
Contributor
Contributor

in a formula i use a field that points to an attribute that prompts for a value. the formula does not compute i believe because it treats the input as text. how do i get the input value to be treated as a number?

0 Likes
Message 5 of 21

vinodkl
Mentor
Mentor

Hi,

 

Can you post the file, so that I can help you out?

--------------------------------------------------------------------------------------------------------------------------
ವಿನೋದ್ ಕೆ ಎಲ್( System Design Engineer)
Likes is much appreciated if the information I have shared is helpful to you and/or others.

Please mark "Accept as Solution" if my reply resolves the issue or answers your question, to help others in the community.
--------------------------------------------------------------------------------------------------------------------------
0 Likes
Message 6 of 21

ChicagoLooper
Mentor
Mentor

What is that attribute?

What e-x-a-c-t-l-y is the field?

What is the formula?

Why is everything a secret?

Keep an open mind because it may not even be a text vs number issue, it might be something completely unknown to you but you can't see it so you are considering only text vs number and ignoring all other possibilities while the solution is right in front of you, correct?

Chicagolooper

EESignature

0 Likes
Message 7 of 21

peter_goodwin
Contributor
Contributor

a simple block , i enter a value and have it multiplied by 7.

0 Likes
Message 8 of 21

pendean
Community Legend
Community Legend
What object is it pointing to that it has to multiply by 7?
0 Likes
Message 9 of 21

peter_goodwin
Contributor
Contributor

THERE ARE ONLY 2 OBJECTS IN THE BLOCK. AN MTEXT CONTAINING TEXT AND A FORMULA AND AN ATTRIBUTE. I WANT THE FORMULA TO MULTIPLY THE VALUE OF THE ATTRIBUTE BY 7.

0 Likes
Message 10 of 21

pendean
Community Legend
Community Legend
So that's not how FIELDs work AFAIK: you're thinking of an Excel style cell formula, where you type something and a calculation takes place on what you entered to change it, correct?

0 Likes
Message 11 of 21

ChicagoLooper
Mentor
Mentor

Please answer these questions. Thanks.

  1. Is this for a viewport scale?
  2. Do you print from a layout tab? 
  3. If you print from a layout tab, is there a reason you put your block in modelspace? (If you print from a layout tab with a viewport, then you can easily put your block on a layout tab and use the Custom Scale field that's associated with the viewport.)
  4. If you print from modelspace, would you be interested in printing from a layout tab which will make the procedure easier? 

Chicagolooper

EESignature

0 Likes
Message 12 of 21

peter_goodwin
Contributor
Contributor

i guess my question is to simple. if i put a default value in the attribute it will calculate the formula with that value, but if i enter the value when prompted it will not use the entered value. Why?

0 Likes
Message 13 of 21

peter_goodwin
Contributor
Contributor

the custom scale uses a rounded value and only provides a correct value if there is no rounding required (50 scale is .02, works fine ,40 scale is .025 which it rounds to .03 and yields a false value.)

0 Likes
Message 14 of 21

vinodkl
Mentor
Mentor

Hi,

 

I guess I have answered your question in post (message) 2. Please check the screencast. 

--------------------------------------------------------------------------------------------------------------------------
ವಿನೋದ್ ಕೆ ಎಲ್( System Design Engineer)
Likes is much appreciated if the information I have shared is helpful to you and/or others.

Please mark "Accept as Solution" if my reply resolves the issue or answers your question, to help others in the community.
--------------------------------------------------------------------------------------------------------------------------
0 Likes
Message 15 of 21

ChicagoLooper
Mentor
Mentor

It appears to be the field. You are not using the field correctly. For example, it might be the wrong field and there might be another field that's more appropriate but you don't know about that field, it might be an incorrect formula, the field you want might not exist but you may be able to combine two or more separate fields to get what you want.

 

Just because you have created a 'formula' that contains a field, doesn't necessarily mean the formula will produce the results you want.   

Chicagolooper

EESignature

0 Likes
Message 16 of 21

ChicagoLooper
Mentor
Mentor

@peter_goodwin wrote:

the custom scale uses a rounded value and only provides a correct value if there is no rounding required (50 scale is .02, works fine ,40 scale is .025 which it rounds to .03 and yields a false value.)


Incorrect. This is your problem, you misunderstand the Custom Scale Field, the custom scale field may, or may not, perform rounding of decimals. The custom scale's precision can be controlled by you and your ability to click your mouse and select the correct options.

 

Additionally, if this is for a viewport scale, then you don't even have to enter anything because the formula, not your formula but another formula, will automatically determine the result without any input from you. 

Chicagolooper

EESignature

0 Likes
Message 17 of 21

peter_goodwin
Contributor
Contributor

as a user, i want to key in a numeric value for multiple attributes of a block to use. that is all.

0 Likes
Message 18 of 21

R_Tweed
Advisor
Advisor

It works fine in my drawing. Am I missing something?

0 Likes
Message 19 of 21

peter_goodwin
Contributor
Contributor

Great, now i need it to work as a block

0 Likes
Message 20 of 21

R_Tweed
Advisor
Advisor

ok..It still works. I made another block with the mtext. You will need to refresh fields with a regen or save depending on your filed update settings. I think you could do the field in an attribute as well.  this will at least allow you to override the text or maybe this is so no-one can override the text.

0 Likes