Results 1 to 3 of 3

Thread: [2005] XML / Recent Documents

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Sep 2005
    Location
    Alaska
    Posts
    435

    [2005] XML / Recent Documents

    I'm almost done with my studio program and need to finish implementing the recent documents feature.

    I already have a functin that pulls the data from an XML file and I'm pretty positive I can easily finish the part that adds an entry to the XML file. My true problem is when I run my query function, how can I only pull the last 5 results?

    XML: RecentDocuments.xml
    Code:
    <?xml version="1.0" encoding="utf-8"?>
    <FXStudio>
    	<RecentProjects>
    		<Project name="Document Title">FilePath</Project>
    	</RecentProjects>
    </FXStudio>
    Basically this is what I'm trying todo:
    Code:
    <?xml version="1.0" encoding="utf-8"?>
    <FXStudio>
    	<RecentProjects>
    		<Project name="Document Title1">FilePath1</Project>
    		<Project name="Document Title2">FilePath2</Project>
    		<Project name="Document Title3">FilePath3</Project>
    		<Project name="Document Title4">FilePath4</Project>
    		<Project name="Document Title5">FilePath5</Project>
    		<Project name="Document Title6">FilePath6</Project>
    	</RecentProjects>
    </FXStudio>
    And the outputed entries:
    Document Title 6
    Document Title 5
    Document Title 4
    Document Title 3
    Document Title 2

    Thanks.

  2. #2
    The Devil crptcblade's Avatar
    Join Date
    Aug 2000
    Location
    Quetzalshacatenango
    Posts
    9,091

    Re: [2005] XML / Recent Documents

    Well, if you are only interested in the last 5, why not only store the last 5? Wouldn't that make reading the whole list in a lot easier?
    Laugh, and the world laughs with you. Cry, and you just water down your vodka.


    Take credit, not responsibility

  3. #3

    Thread Starter
    Hyperactive Member
    Join Date
    Sep 2005
    Location
    Alaska
    Posts
    435

    Re: [2005] XML / Recent Documents

    I figured since the entries will change alot, as in everytime a new document is saved, it will be added to the list. As well I'm going to make it so they can delete entries from the top 5 and thus the next entry will show up.

Posting Permissions

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



Click Here to Expand Forum to Full Width