Raised This Month: $51 Target: $400
 12% 

Reading from two files.


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
vamppa
Senior Member
Join Date: Apr 2010
Location: The Netherlands
Old 08-21-2013 , 17:00   Reading from two files.
Reply With Quote #1

Hello

Am I able to open two files with fopen and read from them?
defining both with iz_File

PHP Code:
new sz_File[128], sz_FileII[128];
get_configsdir(sz_File,127);
format(sz_File,127,"Oke.ini",sz_File);
get_configsdir(s_FileII,127);
format(sz_FileII,127,"sexouZe.ini",sz_FileII);

new 
iz_File=fopen(sz_File,"rt") && ( sz_FileII,"rt"); 

Last edited by vamppa; 08-21-2013 at 17:03.
vamppa is offline
YamiKaitou
Has a lovely bunch of coconuts
Join Date: Apr 2006
Location: Texas
Old 08-21-2013 , 17:24   Re: Reading from two files.
Reply With Quote #2

Quote:
Originally Posted by vamppa View Post
Hello
Hi

Quote:
Am I able to open two files with fopen and read from them?
Yes

Quote:
defining both with iz_File
No
__________________
ProjectYami Laboratories

I do not browse the forums regularly anymore. If you need me for anything (asking questions or anything else), then PM me (be descriptive in your PM, message containing only a link to a thread will be ignored).
YamiKaitou is offline
vamppa
Senior Member
Join Date: Apr 2010
Location: The Netherlands
Old 08-21-2013 , 17:27   Re: Reading from two files.
Reply With Quote #3

damn had an feeling that was the case.
alright other question.

Can I change the order it reads from one file?
- lets say the 1st time I want it to read from top - bottom
- 2nd time from bottom - top
- or 3rd time randomly
vamppa is offline
YamiKaitou
Has a lovely bunch of coconuts
Join Date: Apr 2006
Location: Texas
Old 08-21-2013 , 17:47   Re: Reading from two files.
Reply With Quote #4

Quote:
Originally Posted by vamppa View Post
Can I change the order it reads from one file?
Using fseek, yes
__________________
ProjectYami Laboratories

I do not browse the forums regularly anymore. If you need me for anything (asking questions or anything else), then PM me (be descriptive in your PM, message containing only a link to a thread will be ignored).
YamiKaitou is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 23:16.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode