Re: Win32Lib: making a "List Table"?
On Wed, 2 Feb 2000 04:44:16 -0800, Dan B Moyer <DANMOYER at PRODIGY.NET> wrote:
>Brian,
>
>That is a nifty looking list box! I think I *could* make it work for me,
>but it looks like I'd have to "parse" any given line in it to get a
>particular column's info OUT, and copy & rebuild a line to put individual
>column info INTO it, & my way of putting a series of list boxes next to
each
>other lets me easily act to write or read to whichever column/ListBox I
>want.
>
>Without some kind of "ListTable" control, looks like it is a choice between
>your more easily constructed single list, with more difficult column info
>input & extraction, and my more difficult to construct series of list boxes
>with easier input & extraction of column info. I may end up using yours.
>Thanks.
>
>Dan Moyer
Dan,
It's actually pretty easy to get at the data. In my example, try something
like this:
---------------------------- UNTESTED CODE ------------------------------
function parseListData(sequence tabbedText)
-- takes "x\ty\tz" and returns {x,y,z}
integer x
sequence returnData
returnData = ""
x = match("\t", tabbedText)
while x do
returnData = append(returnData, tabbedText[1..x-1])
tabbedText = tabbedText[x + 1..length(tabbedText)]
x = match("\t", tabbedText)
end while
return returnData
end function
|
Not Categorized, Please Help
|
|