Indigo Rose Software

Professional Software Development Tools

 
+ Reply to Thread
Results 1 to 10 of 10
  1. #1
    Join Date
    Feb 2009
    Posts
    6

    Star I Need Help pls - ListBox


    Hello,

    I cant show text file from listbox in a pragraph

    please tell me how

    show My project in attachments

    Thanx alot
    Attached Files

  2. #2
    Join Date
    Apr 2007
    Location
    Raalte, OV, Netherlands
    Posts
    3,287
    woah almost one letter per page just kidding...

    Please attach the exported project file (File > Export)
    Bas Groothedde
    Imagine Programming :: Blog :: Familiar people here

    My AMS Plugins:

  3. #3
    Join Date
    Feb 2009
    Posts
    6

    thx

    thanx

    am sorry take a export file in attach

    thanx alot
    Attached Files

  4. #4
    Join Date
    Mar 2007
    Location
    HeaveN
    Posts
    534
    here is a good example for you
    Attached Files

  5. #5
    Join Date
    Feb 2009
    Posts
    6
    hi Jack

    Thanx for Example

    but i want show a text file from Docs Directory to Paragraph chose from listbox

    lock attachment

    thx again
    Attached Files

  6. #6
    Join Date
    Jan 2006
    Posts
    31
    First of all ... hi.

    I am not as skilled as others, but i hope this will help you.

    I know there is an "easier" solution, but sorry.

    Anyway hope this will help you

    ((Hope it's that what you want ... I'm a bit confused at the moment ^^))
    Attached Files

  7. #7
    Join Date
    Mar 2007
    Location
    HeaveN
    Posts
    534
    Put this code sto ur project and try...

    Page On Show Code :
    Code:
    tEntries = File.Find("AutoPlay\\Docs\\", "*.txt", false, false, nil, nil);
    nEntries = Table.Count(tEntries);
    nEntriesStart = 1;
    repeat
    	tPath = String.SplitPath(tEntries[nEntriesStart]);
    	ListBox.AddItem("ListBox1", tPath.Filename, tEntries[nEntriesStart]);
    	nEntriesStart = nEntriesStart + 1;
    until nEntriesStart > nEntries
    ListBox On Select Code :
    Code:
    tSelected = ListBox.GetSelected("ListBox1");
    if tSelected ~= nil then
    	for index in tSelected do
    		sSelected = ListBox.GetItemData("ListBox1", tSelected[index]);
    		sSelectedText = TextFile.ReadToString(sSelected);
    		Paragraph.SetText("Paragraph1", sSelectedText);
    	end
    end

  8. #8
    Join Date
    Feb 2009
    Posts
    6

    Smile thx

    XeroX

    Thanx aloooot
    yes this is good now is working

    thank u thank u brother so mutch

    Jack

    am try your code but in page code when i perview show message is line 2 problem can u check and thanx for every thing brother

    i'll wait u

  9. #9
    Join Date
    Mar 2007
    Location
    HeaveN
    Posts
    534
    ok try like that;

    Page On Show Code :
    Code:
    tEntries = File.Find("AutoPlay\\Docs\\", "*.txt", false, false, nil, nil);
    if tEntries ~= nil then
    nEntries = Table.Count(tEntries);
    nEntriesStart = 1;
    repeat
    	tPath = String.SplitPath(tEntries[nEntriesStart]);
    	ListBox.AddItem("ListBox1", tPath.Filename, tEntries[nEntriesStart]);
    	nEntriesStart = nEntriesStart + 1;
    until nEntriesStart > nEntries
    end
    ListBox On Select Code :
    Code:
    tSelected = ListBox.GetSelected("ListBox1");
    if tSelected ~= nil then
    	for index in tSelected do
    		sSelected = ListBox.GetItemData("ListBox1", tSelected[index]);
    		sSelectedText = TextFile.ReadToString(sSelected);
    		Paragraph.SetText("Paragraph1", sSelectedText);
    	end
    end

  10. #10
    Join Date
    Feb 2009
    Posts
    6

    Smile

    hi jack

    is work ok but i dont want showing a txt file name in the list i want is work with my list

    thanx so mutch man

Similar Threads

  1. ListBox indexing explained
    By Adam in forum AutoPlay Media Studio 7.5 FAQ
    Replies: 0
    Last Post: 11-01-2007, 01:58 PM
  2. Listbox problem
    By krayten in forum AutoPlay Media Studio 6.0
    Replies: 32
    Last Post: 07-09-2007, 03:57 AM
  3. On Audio Codes - Pls Check
    By SiNisTer in forum AutoPlay Media Studio 6.0
    Replies: 20
    Last Post: 05-22-2007, 09:03 AM
  4. ListBox - How to autoscroll?
    By azmanar in forum AutoPlay Media Studio 6.0
    Replies: 6
    Last Post: 01-17-2007, 07:09 AM
  5. Example: Using the ListBox object
    By Ted Sullivan in forum AutoPlay Media Studio 5.0 Examples
    Replies: 0
    Last Post: 05-07-2004, 12:24 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts