locked
data-win-selectable has no effect

    Question

  • Hello everybody,

    so I've created a standard blank application and added the following html code:

    <p id="para1" data-win-selectable="true">
            Some demo text...
    </p>

    However, I'm not able to select the text. Not in the simulator, not on my machine. Mouse pointer also stays the same (an arrow). What am I doing wrong? Sorry, if it's a real stupid question… thanks!
    Thursday, March 22, 2012 1:29 PM

Answers

  • The documentation is out of date.  See this guide at the top of the forum (it is a sticky post) for the correct attribute:

    Migrating Windows 8 Developer Preview code to Consumer Preview

    Basically you do something similar to this in your style sheet:

    #para1
    {
        -ms-user-select: element;
        cursor: text;
    }

    -Jeff


    Jeff Sanders (MSFT)

    Thursday, March 22, 2012 3:07 PM
    Moderator