Solved

List View

Posted on 1997-04-30
1
189 Views
Last Modified: 2010-04-04
Dear Experts,I wish to fill a list view with Items and SubItems from an INI file as follows:



Heading1    | Heading2
-------------------------------------
A           | Data for A
B           | Data for B
C           | Data for C
D           | Data for D
...


so the INI file would look something like:

[Heading1]
Value=A,B,C,D ...

[Heading2]
Data="Data for A","Data for B","Data for C","Data for D" ...


I've tried various methods including CommaText and LoadFromFile but can't seem to get it 100%
succesful, I had a wierd thing with CommaText, the first Item wasn't read properly, it completey
ignored the first set of quotes!

Any help would be appreciated, as I don't want to hard code the data into the program.

Thanks in advance,
Antony
0
Comment
Question by:antony burden
1 Comment
 

Accepted Solution

by:
lkovac earned 100 total points
ID: 1335797
You can do it this way:

[Values] {use any name of the section here you wish}
A=Data for A
B=Data for B
C=Data for C
D=Data for D

etc...

This section would be dedicated only for data in the list.

However, if this is Delphi 2.0 (or even 3.0) and 32 bit world, use rather Registry, with about the similar context: one folder (key) in the registry with string items inside (I expect the Data are strings; but here you can use even DWORDs and similar types).
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.
Many functions in Excel can make decisions. The most simple of these is the IF function: it returns a value depending on whether a condition you describe is true or false. Once you get the hang of using the IF function, you will find it easier to us…

911 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now