Results 1 to 2 of 2
  1. #1
    ychen42 is offline Member
    Join Date
    Nov 2010
    Rep Power

    Question im starting a project soon but want some tips/help

    hi all, i am taking a java class this semester and its time for a final project

    my final project is to make a gui that is sort of a search engine for shakespeare plays
    maybe 5-10 plays(ie hamlet, romeo&juliet, macbeth etc) total i think, not sure about that

    so the gui will ask the user for a word/phrase

    when the user hit search, the program will find all the occurrences of the word/phrase in the selected plays

    so the output of this would be a gui that displays the word/phrase and where the phrase occurs along with the play name, line, act, and scene

    im thinking this will take about 1k+ lines of coding...

    i am familiar with making GUIs but i am clueless about how to search through a txt file to fine the word/phrase

    can someone give me some sites or short tutorials for something like that???

    ive googled n im not finding what im looking for...
    Last edited by ychen42; 11-12-2010 at 12:30 AM.

  2. #2
    Zack's Avatar
    Zack is offline Senior Member
    Join Date
    Jun 2010
    Destiny Islands
    Rep Power


    File (Java 2 Platform SE 5.0)
    Lesson: Basic I/O (The Java™ Tutorials > Essential Classes)

    Basically, once you have your keyword, you want to loop through every line in the file and see if it contains the keyword (using String methods like indexOf() or contains()).

Similar Threads

  1. i need some tips on this question
    By reeveliew in forum New To Java
    Replies: 13
    Last Post: 06-15-2010, 05:29 PM
  2. Tips needed
    By adz06 in forum New To Java
    Replies: 5
    Last Post: 12-07-2009, 01:35 AM
  3. need some derby tips:
    By kulangotski in forum Advanced Java
    Replies: 4
    Last Post: 03-09-2009, 05:09 PM
  4. Need some tips.
    By PVL268 in forum New To Java
    Replies: 4
    Last Post: 02-27-2009, 02:37 PM
  5. First project, need some tips..
    By Komala_aradhya in forum New To Java
    Replies: 1
    Last Post: 08-03-2007, 01:25 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts