• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Jeanne Boyarsky
  • Junilu Lacar
  • Henry Wong
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Frits Walraven
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • salvin francis
  • fred rosenberger

How to add dynamically RDF resources ?

 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
[size=12] [color=black]
I have a jframe  with jcombo boxes and that frame  allows to add dynamically JCombo boxes , and the items of jcombo boxes are URIs that I have extracted from an ontology ,so whenever I click on "add" button new jcombo boxes  boxes will be added to my jframe.
this is my code for adding jcomboBoxes :

I have also a button "generate RDF" for generating RDF file of the different URIS of the different jcomboBoxes,for example I want my rdf file to describe 4 URIS so I add 4 jcomboboxes to my jframe an I select for each one a diffrent URI but the problem is that it only works for the first URI and the 3 others are identical,despite I have selected different URIS.
this my code for generating rdf file  :

So how can I fix this problem ?
[/color][/size]
 
Rancher
Posts: 179
15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Without having much of the context here, my assumption would be that c4 is always set to the most recently added JComboBox due to this line:

And then c4 is later used to find the file to write:


I'm suspicious of this empty loop:

You probably meant to do something here (for example, loop through all components/combo boxes)
 
Yamna Ghazi
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
@Zachary Griggs
Yes ,c4 is the new combo box that will be added dynamically to my jframe whenever I click on the button "add",my goal is to add dynamically combo boxes then I generate rdf file to describe all the URIs of the combo boxes.
 
Doody calls. I would really rather that it didn't. Comfort me wise and sterile tiny ad:
Devious Experiments for a Truly Passive Greenhouse!
https://www.kickstarter.com/projects/paulwheaton/greenhouse-1
    Bookmark Topic Watch Topic
  • New Topic