This week's giveaway is in the EJB and other Java EE Technologies forum. We're giving away four copies of EJB 3 in Action and have Debu Panda, Reza Rahman, Ryan Cuprak, and Michael Remijan on-line! See this thread for details.
few questions: 1. how do i select some text, provided i know the positions of start and end. i tried jtextpane.select(pos1,pos2); but it didnt mark the text, it only moved the caret to pos2. 2. how do i prevent a user from typing any text in the textpane? however i want him to be able to click on words in the textpane summarizing the above two questions: my requirement is to select/mark a word on which the user clicks. any inputs on this would be appreciated.