我想在JTable的每一行中显示数据库中的所有类别。 现在,当我点击JTable的每一行时,我需要显示其下的产品列表(被视为该类别的子项)作为下拉列表而不是作为下拉列表,当焦点丢失时自动关闭,但它应该保持直到我点击同一行中的最小化图标。 这就像扩展内容一样。 所以我可以单独扩展所有类别。 工作类似于JTree,但我需要它在JTable中,以便我可以以适当的格式显示每行的更多信息。 有任何想法吗 ?
I want to show all the categories in the database in each line of a JTable i have done that. Now when i click on the each row of JTable i need to show the list of products under it (considered as child of the category) as a drop down not as a drop down list which closes automatically when focus is lost, but it should stay there until i click on minimize icon in the same row. It is just like expanding content. so i can expand all categories individually. The working is similar to JTree but i need it in JTable so that i can show more information on each row in a proper format. Any ideas ?
最满意答案
您需要TreeTable功能。 我打赌这篇文章会对你有所帮助。
You need TreeTable functionality. I bet this article will help you.
更多推荐
发布评论