java - Displaying from database issue -


I am doing an assignment with Java in Eelpse Indigo. I have to create a program for a school and that program is a spell check program. I am able to assist the staff; Students also log on and change their passwords and edit their accounts. I am also able to reach them to create and edit the test. But one thing that I can not see is available available in a list of available tests to see how many tests have been set. I do not know what will be the change in my code to fix this problem. To display tests, I've created a method called displayTest . I've created storage for testing using hashfile . I

Here I have saved storage for testing in an hashfile .

  string test_FILENAME = "datafiles / test.dat"; Hashfile testFile = new hashfile (test_FILENAME, 100, new test ());   

I have continued to add a test (there is storage for variable testing at the top of my coding document):

  public zero addTest (test) Test = new test (); // Create a storage for a teacher test.input (); // Read teacher details through keyboard test. File.store (test); // Store the Teacher in Teacher File   

I am also able to edit the account using it (I am using PC etc. from another class):

  public zero editTest () {no string test; PC_Dialog editTests = New PC_Dialog ("edit test", "test no", "find"); // Create a dialog box to ask for editing the teacher numbers tests.choice (); // Do not display dialog box test = editTests.getField (21); // Do not receive the teacher, which has entered the exam = (test) testFile.retrieve (testNo); // Recover the teacher from the file (test! = Null) {// Check whether the teacher has received the exam. Edit (); // yes then display it to edit testFile.store (test); // Store the teacher back in the teacher file} Other joppenpen.She Mesejidiag (empty, "unable to find the test!"); // if not found, error message} // end of method   

but I have some problems in displayTest () . Disapplyists mean that all the tests for teachers Allow to see what edits and which ones to click a button but the problem is that if (test.year == year) << em> has a red line under the first year and when I say it, ' year is not solved Can be or no field ' What does testing someone could help me out and display Test Test section data file and display them on a table? I am new to Stackoverflow and used it only once a year ago. I apologize if someone gets disappointed by the work of newcomers, but this is my first time using Stakeoverflow. Thank you very much, thanks.

I changed the code from:

  public zero performance test () {test test = not new test (); Test year group = new test (); Test date = new test (); PC_Table Table = New PC_Table ("Test Available", 0, "Test Number, Date, Year Group", "OK"); Int row = 1; // Prepare the file for a counter // serial access testFile.resetSerialAccess () for the current line; // While loop through all the records in the event file (testFile.moreSerialRecords ()) {// next record test test = (test) testFile.getNextSerialValue (); {// Reclaim the cause / add a line table and enter the value in the table .addRow (); Table.setValueAt (test.testNo, line, 1); Table.setValueAt (test.date, line, 2); Table.setValueAt (test.yearGroup, line, 3); Line ++; } Table.choice ();   

-text "itemprop =" text ">

you have

  test date = new test ();   

The name of the "test" category is "date" is the name of that class example. You say that is in error

  if (test.year == year)   

I do not see this line in code, but what do you

  If (date.year == year)   

Good luck!

Comments

Popular posts from this blog

c - Mpirun hangs when mpi send and recieve is put in a loop -

python - Apply coupon to a customer's subscription based on non-stripe related actions on the site -

java - Unable to get JDBC connection in Spring application to MySQL -