web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Supply chain | Supply Chain Management, Commerce
Suggested Answer

How to apply HTMLElement in TypeScript to HTML

(0) ShareShare
ReportReport
Posted on by

Hi everyone, I try to make Dual Display Sample in Retail mPOS.

What I have done:

- I ReDesign layout Dual Screen.

One side I show the Cart Line Item, another side I show Video.

pastedimage1588152033255v1.png

What my issue:

- I want a hidden side cart line Item when no Item in the cart. I try: data-bind="attr: {hidden: ishidden}".

pastedimage1588152379127v2.png

When I set ishidden = true, it ok, but set = false not effect.

After that, I try to use HTMLELEMENT to set and remove hidden attributes.

pastedimage1588152645384v3.png 

But it does not affect to HTML. 

I have the same question (0)
  • Suggested answer
    ahgamal Profile Picture
    on at

    Hi Duy

    i think using the data-bind is fine and should work , you have mentioned that it works when the property is set to true which mean that the th is hidden but for some reason setting it to false did not work.

    can you try instead of setting the hidden property to try to set the class itself so we will have two style class , one to hide and one to display the th and then use the same way you did to set the hidden property to set the class style  instead

    ex.

    <!DOCTYPE html>

    <html>

    <head>

    <style>

    th.Hide {

     display:none;

    }

    th.display {

     display:normal;

    }

    </style>

    </head>

    <body>

    <table class="a">    

    <tr>

    <th>Col 1</th>

    <th  class="Hide" >Col2</th>

    </tr>

    </table>

    </body>

    </html>

  • Community Member Profile Picture
    on at

    Thank you reply. It working. But I want to ask you one question: Have a way to use htmlelemt?

  • ahgamal Profile Picture
    on at

    you should be able to use it in the corresponding TypeScript file.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Supply chain | Supply Chain Management, Commerce

#1
Laurens vd Tang Profile Picture

Laurens vd Tang 299 Super User 2025 Season 2

#2
Siv Sagar Profile Picture

Siv Sagar 183 Super User 2025 Season 2

#3
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 117 Super User 2025 Season 2

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans