Programming Forums

Programming Forums (http://www.programmingforums.org/forumindex.php)
-   C++ (http://www.programmingforums.org/forum15.html)
-   -   .lst File Help needed / Parsing (http://www.programmingforums.org/showthread.php?t=2705)

JamesLomuscio Mar 10th, 2005 4:26 PM

.lst File Help needed / Parsing
 
I can't find anywhere a class that is able to grab data from a .lst (list) file.
Ideally, I'd like to find something that could get me my data like this:
void Get_Data(variable_type, variable_section, variable_key, variable_to_store_data_in);

If ANYONE knows ANYTHING about .lst files, or Parsing in general, I beg you to respond.

Thanks in advance.

brkstf Mar 10th, 2005 5:16 PM

don't know exactly what a .lst file is, but it sounds like you want to take data from a dbase dump file and use it for something.

get data line by line by using a while loop on an IFSTREAM checking for the return character. then, split each line based on the delimiter, which is normally a comma or tab character. after that, you're on your own for how to re-cast the text as data items, etc. it's really not that hard.

also, don't use "void" unless you really mean it. this function should return at least a success/fail.


All times are GMT -5. The time now is 4:02 PM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC