Adding a scrollable label to an option dialog

I am creating an options dialog using `JOptionPane.showOptionDialog(...)` When I click one of the buttons added to this dialog, I need a label to apear underneath on the dialog (and this label should be scrollable if necessary). I have written event handlers for the buttons, but I am not sure how to get this label to appear on the dialog. Any help would be great. **Update:** I realized that it would be ok if I somehow called `JOptionPane.showOptionDialog(...)` with an initial message, and then when one of the buttons was clicked I would change the message. Is this possible?
@llm: Are you that you need JOptionPane.showOptionDialog? Wouldn't subclassing a JDialog be easier?

以上就是Adding a scrollable label to an option dialog的详细内容,更多请关注web前端其它相关文章!

赞(0) 打赏
未经允许不得转载:web前端首页 » JavaScript 答疑

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址

前端开发相关广告投放 更专业 更精准