check if variable is defined
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
check if variable is defined
Hi,
my problem sounds rather simple but still I do not a have a solution in Mathcad. In order to automate my Mathcad 14 sheets I would like to check if a variable is defined or not.
If the variable is defined (not red colored in Mathcad) this on should be used instead of an different.
Thanks
Holger
Solved! Go to Solution.
- Labels:
-
Other
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi Holger,
I was not able to view Richard's solution, since I cannot open .mcd files, only .mcdx. I was wondering if you could possible provide a screenshot of the solution?
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
The solution is a hack job using scripted components to trap the error. Scripted components are not available in Prime though, so the solution does not apply. There is no way to trap an undefined variable error in Prime and handle it gracefully. Why do you need to do this though? The original poster wanted this because they were calling worksheets from other software via the automation interface. In MC14 (and MC15) there is then a very good reason why you would want to check whether or not a variable is defined, but in Prime it is not necessary to do so.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi Tyler,
Please find the contents of the Mathcad worksheet in attachment in PDF and XPS file formats and on screenshots below:
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
You wrote originally "In order to automate my Mathcad 14 sheets I would like..." So why can't you open .mcd files?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Luc,
The very first post in this thread belongs to Holger, not Tyler.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
You're right. Confusion on my part.
