开发者

How can i use/insert HashTable Key and values into a JTable? [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center. 开发者_如何学Go Closed 11 years ago.

I want to use HashTable keys & value in a JTable. How can i do this ?


first: make yourself familiar with the use of tables

http://download.oracle.com/javase/tutorial/uiswing/components/table.html

and datamodels

http://download.oracle.com/javase/6/docs/api/javax/swing/table/DefaultTableModel.html

if you know, how to add data in a JTable, you can iterate over your HastTable by a foreach-loop

for(Map.Entry<K,V> entry : hashTable.entrySet()) {

for further information, see

http://download.oracle.com/javase/6/docs/api/java/util/Hashtable.html

and

http://download.oracle.com/javase/6/docs/api/java/util/Map.Entry.html

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜