locked
Can I play a sound out of link from a single word in a RichTextbox? RRS feed

  • Question

  • I've got a richtextbook on the canvas.  I want to have a paragraph with one word

    or ten separate words highlighted so that when the user clicks on the word it pronounces

    the Greek word for them.  How do I do that? The playsound behavior activates the whole
    richtextbook, How do I get down to single words in the textbox.  The hyperlink only lets

    me link to URL's.  Any suggestions?


    ted7
    Sunday, April 17, 2011 1:25 PM

All replies

  • You could use individual textboxes in a stackpanel or a wrappanel? Then each one can have its own play sound behavior.
    Monday, April 18, 2011 4:03 PM
    Moderator
  • Okay I can do that.  Two things would make it easier.  Can I use HTML in the Rich Textbox and use

    an HTML trigger on a word to kick out an event that I can capture to say "Word 4 has been clicked."
    A second feature that I've used in Flash/Director other programs I've worked with there was a "Word selected" feature that if someone
    clicked on word 124 you could capture that word selector and do something off of it.  That seems a lot
    smarter if Silverlight doesn't have that it is a basic staple for those of us that still work with text.
    Doing each word in it's own textbox in a stackpanel will have to do for now but there needs to be a way to

    fire off events directly from clicking on a word in a textbox.  I wondering if that can be done in Silverlight????


    ted7
    Tuesday, April 19, 2011 11:04 AM