×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

How do you show the result of a function without showing the name

How do you show the result of a function without showing the name

How do you show the result of a function without showing the name

(OP)
In my design sheets I want to append a series of calculations with something like "ok" or "x > y, OK", but am not sure how to do this without ending up with something like: F= "OK".

Is there any way to do this? Can I make a function off to the side and somehow call it without displaying the name of the function?

Thanks.

RE: How do you show the result of a function without showing the name

You could create an "Area", put the calculations you want to hide in the "Area", then "Collapse" the "Area", and if desired, "Lock" it with a password, so that the hidden calculations can not be viewed without a password.

You can display the result of the hidden calculations outside the "Locked Area", so the result can still be seen, but the working can not. Just use a syntax like this to assign a result in the hidden working:

     Result := MyFunction (parameter1, parameter2, ...)

Then below the hidden area, use syntax like this to display the result:

     Result =

and you should get the output displayed something like this:

     Result = "OK"

but the function  used to generate the result won't be displayed.

Search the Mathcad Help file for "Grouping and Protecting Information with Areas" for more information.

We use this method to hide calculations which contain a lot of sensitive Intellectual Property, but we only distribute the printed / PDF output, NOT the native Mathcad file, because I am never too sure how secure such password protection schemes are, but it should be good enough to hide the working from casual "prying eyes". (I know there are password crackers for Excel, and I suspect the same can be done with Mathcad passwords, if you know how.)

Another approach is to put all the calculations you want to keep hidden on the right side sheet of the formatted output, and select "Print single page width" on the "Page Setup" menu. This only affects the printed output, but again, if you are only distributing "hard copy", it will have the desired effect.

Hope this helps!

RE: How do you show the result of a function without showing the name

To display a result without displaying the name of the function you can use a text box.  Go to Insert > Control > Text box.  Right click on the box, then remove output variable, and add input variable.  Then edit the script to read TextBox.Text = Inputs(0).Value.  Then right click the text box again and select hide arguments.

Peter

RE: How do you show the result of a function without showing the name

Another option is to assign a picture (bitmap) of the tick (OK) or cross (X) etc. Then display the picture. You can hide the arguments for a picture.

Philip

RE: How do you show the result of a function without showing the name

(OP)
Thank you all I'll give these a try!  

RE: How do you show the result of a function without showing the name

I like to see what test caused the result.  So, I use an "if" statement. It ends up looking like this:

if(øMn>Mu,"O.K.","N.G.")=O.K.

 

RE: How do you show the result of a function without showing the name

There's a guy on the Mathcad Collab that used to post GIFs of stuff with tricks.  One trick is to use an invisible font for the variable being displayed.  This would leave you with

=xyz

as the only thing visible.

TTFN

FAQ731-376: Eng-Tips.com Forum Policies

RE: How do you show the result of a function without showing the name

What I do is BucklingStrength: if(øMn>Mu,"O.K.","N.G.") and then lower down I use BucklingStrength=

RE: How do you show the result of a function without showing the name

Oh, and with the Excel component approach, you can also apply conditional formatting, so that you get OK and NG

TTFN

FAQ731-376: Eng-Tips.com Forum Policies

RE: How do you show the result of a function without showing the name

pstuckey,

I've been trying for years to do something like this.  kudos!  I can use this method to to display all kinds of errors and other messages.  And they don't have those ugly quote marks that I get with text variables.  

My only disappointment is that somewhat ugly box that appears around the text.  But I think I can live with that.

Thanks for a  great tip.


regards,


chichuck

 

RE: How do you show the result of a function without showing the name

(OP)
Actually when you use the text box you can go to the properties area and remove the box around the text! Just right click the box, and go to Mathsoft text box control object > properties > extended styles and mine generally comes up as client box, so just deselect that.  

RE: How do you show the result of a function without showing the name

imerich,

I was fiddling with it and I found that.  Now I can make the messages look just like I want them to.  If only I could conditional format them to be green when its okay and red when its ng, or make it disappear with a white font on a white background when not needed, then I couldn't ask for more!

 

RE: How do you show the result of a function without showing the name

Read IRStuff's 6/25 post.

Quote:

Oh, and with the Excel component approach, you can also apply conditional formatting, so that you get OK and NG

RE: How do you show the result of a function without showing the name

you can add this line before your result:

TextBox.Forecolor = RGB(0,0,225)

cheers
 

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources