Mutilined text boxes


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 3 of 3

Thread: Mutilined text boxes

  1. #1
    Join Date
    Sep 2004
    Location
    Northampton,United Kingdom
    Posts
    230

    Mutilined text boxes

    Hi all,

    I need some advice on Mutiline text boxes.

    I have a text box that is bound to my database (work fine)

    But I want to send the data from journa_info.text to form1.list1

    I have tryed to use form1.List1.AddItem (Text1.Text)

    But I am ending up with the following

    COKE 0.35 || Eggs 0.39||

    I think the || is to show a CR but I need it to show up as

    COKE 0.35
    Eggs 0.39

    is there a way I can move through the text box line by line and just add that line into my text box?

    Pleeeease can some one help
    Drew

  2. #2
    Join Date
    Nov 2003
    Location
    Portland, OR
    Posts
    8,387
    Code:
    Dim sArray() As String
    sArray = Split(txtBox.Text, vbCrLf)
    
    Dim vLine As Variant
    For Each vLine In sArray
        lstBox.AddItem vLine
    Next
    Phil Weber
    http://www.philweber.com

    Please post questions to the forums, where others may benefit.
    I do not offer free assistance by e-mail. Thank you!

  3. #3
    Join Date
    Sep 2004
    Location
    Northampton,United Kingdom
    Posts
    230
    Thanks again Phil

    Your allways saving my bacon

    Drew

Similar Threads

  1. Creating Scrollable Text Boxes
    By Miles Tones in forum VB Classic
    Replies: 4
    Last Post: 05-26-2005, 10:38 AM
  2. text boxes
    By MacataQ in forum VB Classic
    Replies: 5
    Last Post: 05-01-2005, 04:43 AM
  3. Script for scrolling
    By Mark in forum Web
    Replies: 3
    Last Post: 08-30-2001, 12:45 PM
  4. Double Text 1.0
    By George Gilbert in forum vb.announcements
    Replies: 0
    Last Post: 08-19-2001, 12:34 PM
  5. default value for text boxes.
    By david in forum ASP.NET
    Replies: 0
    Last Post: 08-02-2000, 02:42 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center