Hi,
We have a request to be able to print the page when a button on the Thingworx Dashboard is pressed.
I was checking, if possible, with the HTML Text Area widget, I was trying with below code and it was not working:
<!DOCTYPE html>
<html>
<head>
<title>Print Page Example</title>
</head>
<body>
<h2>This is a sample printable page.</h2>
<p>Click the button below to print this page.</p>
<button onclick="window.print()">Print This Page</button>
</body>
</html>
Thingworx Version: 9.7
Thanks,
Solved! Go to Solution.
Hi @Rocko
Tried everything, nothing worked. According to the use case, I need to insert it into the HTML Text Area, which is currently not possible.
I found a workaround using the value display widget.
Thanks,
Have you considered a search on PTC support? Many articles are available on this topic.
https://www.ptc.com/en/support/search/#q=print%20mashup
Hi @Rocko
Tried everything, nothing worked. According to the use case, I need to insert it into the HTML Text Area, which is currently not possible.
I found a workaround using the value display widget.
Thanks,
HTML Text area is mainly for text display - you can't put active components or JS in there, it will be filtered out.
Yes @Rocko , Agree.