The Daily Click ::. Forums ::. Klik Coding Help ::. List Comparison
 

Post Reply  Post Oekaki 
 

Posted By Message

lembi2001



Registered
  01/04/2005
Points
  608

VIP MemberIt's-a me, Mario!Wii OwnerI like Aliens!Has Donated, Thank You!PS3 OwnerI am an April Fool
15th December, 2009 at 10:46:45 -

I have a text file which contains a list of data that looks like this:

computer-01.xml,Room1
computer-02.xml,Room1
computer-03.xml,
computer-04.xml,Room2
computer-05.xml,Room4
computer-06.xml,

i have another text file which contains just:

computer-01.xml
computer-02.xml
computer-03.xml
computer-04.xml
computer-05.xml
computer-06.xml
computer-07.xml
computer-08.xml
computer-09.xml
computer-10.xml

I want to keep the data in the first list as it contains all the room details but i need to add any extra machines to this list. Is there anyway to do this automatically through MMF2??

In the above examples i would need to add:

computer-07.xml
computer-08.xml
computer-09.xml
computer-10.xml

to the original list.

cheers



 
n/a

Jon Lambert

Administrator
Vaporware Master

Registered
  19/12/2004
Points
  8235

VIP MemberWii OwnerTDC Chat Super UserI am an April FoolSSBB 3265-4741-0937ACCF 3051-1173-8012360 Owner
15th December, 2009 at 12:40:42 -

I suppose you could load both files into separate Rich Text Edit objects and then:
- Start a fast loop for a number of times equal to the number of lines in the filename-only text file.
- Use the 'On loop' condition in a new event and the 'Find String' condition to search for the line whose number is equal to the loop index from the filename list in the filemame/room list.

I don't have time to finish.

 
Sandwich Time!Whoo!

JoyCheck & KeyCheck Widgets
For easy implementation of customizable joystick and keyboard controls.
http://www.create-games.com/download.asp?id=8364

aphant



Registered
  18/05/2008
Points
  1242
15th December, 2009 at 16:25:23 -

Break the problem down: You want to copy from one file and paste into another. How you would do that by hand? Just recreate that process.

 

Sumo148

Super amazing fantastic user

Registered
  26/01/2009
Points
  530

360 OwnerThe Cake is a LieVIP MemberPokemon Ball!I am an April FoolI donated an open source projectSanta Hat
16th December, 2009 at 00:35:24 -

like this ? http://www.mediafire.com/file/4qdzdqkzzgn/list.zip

 
n/a

lembi2001



Registered
  01/04/2005
Points
  608

VIP MemberIt's-a me, Mario!Wii OwnerI like Aliens!Has Donated, Thank You!PS3 OwnerI am an April Fool
16th December, 2009 at 14:28:56 -

Cheers for the example sumo but not sure you understood, i need it to do this automatically and only transfer lines that were not already in the list. Going to try and do it using Jon Lambert's method but if anyone has any other suggestions then please let me know.

cheers

 
n/a

Assault Andy

Administrator
I make other people create vaporware

Registered
  29/07/2002
Points
  5686

Game of the Week WinnerVIP Member360 OwnerGOTM JUNE - 2009 - WINNER!GOTM FEB - 2010 - WINNER!	I donated an open source project
17th December, 2009 at 02:46:41 -

http://mfa.aquadasoft.com/view/1261017656-lembi2001_list

Here it is. Don't ask how it works, it just does . But briefly - it scans through list 2 and checks if the first 15 letters of the current line are found in list 1, if so it adds the line from list 1, if not it adds the the current line from list 2. (This assumes that you have only up to 99 computers. But can easily be adapted if you add more, you just need placeholder zeros like you have.)

I didn't exactly know what you wanted but I tried. There were a few things you didn't explain but hopefully this is what you're looking for.

 
Creator of Faerie Solitaire:
http://www.create-games.com/download.asp?id=7792
Also creator of ZDay20 and Dungeon Dash.
http://www.Jigxor.com
http://twitter.com/JigxorAndy

lembi2001



Registered
  01/04/2005
Points
  608

VIP MemberIt's-a me, Mario!Wii OwnerI like Aliens!Has Donated, Thank You!PS3 OwnerI am an April Fool
17th December, 2009 at 10:38:57 -

Works a treat Andy, Thanks!!! Now to put into my app. On a side note, i like that site a lot, provides a lot of information about an MFA. is it your site??

 
n/a

Jon Lambert

Administrator
Vaporware Master

Registered
  19/12/2004
Points
  8235

VIP MemberWii OwnerTDC Chat Super UserI am an April FoolSSBB 3265-4741-0937ACCF 3051-1173-8012360 Owner
17th December, 2009 at 12:35:49 -

I think it's ViIIy's site, but I'm not sure. It's an Aquadasoft site. Does Villy work for Aquadasoft?

 
Sandwich Time!Whoo!

JoyCheck & KeyCheck Widgets
For easy implementation of customizable joystick and keyboard controls.
http://www.create-games.com/download.asp?id=8364

stephen1980



Registered
  06/07/2009
Points
  1
17th December, 2009 at 19:33:01 -

Yes, Villy works for Aquadasoft.

 
stephen1980

lembi2001



Registered
  01/04/2005
Points
  608

VIP MemberIt's-a me, Mario!Wii OwnerI like Aliens!Has Donated, Thank You!PS3 OwnerI am an April Fool
18th December, 2009 at 13:10:35 -

Thanks again Assault Andy, managed to tweak it so it would work with any number of characters and also found that it removes old items aswell. Fantastic Work!!!

 
n/a

Assault Andy

Administrator
I make other people create vaporware

Registered
  29/07/2002
Points
  5686

Game of the Week WinnerVIP Member360 OwnerGOTM JUNE - 2009 - WINNER!GOTM FEB - 2010 - WINNER!	I donated an open source project
19th December, 2009 at 02:15:17 -

I'm glad that you found it useful

 
Creator of Faerie Solitaire:
http://www.create-games.com/download.asp?id=7792
Also creator of ZDay20 and Dungeon Dash.
http://www.Jigxor.com
http://twitter.com/JigxorAndy
   

Post Reply



 



Advertisement

Worth A Click