|
-
Nov 17th, 1999, 01:03 AM
#1
Thread Starter
Guru
You can have it so that every line of the ListBox shows three words and an ellipsis, and when you click it, the entire item is copied to a MultiLine TextBox.
Example:
The item is:
This is an example of how to show
a MultiLine item in one line
of a ListBox
On the ListBox it shows:
This is an...
When you click it, the entire text is displayed in a MultiLine TextBox.
------------------
Yonatan
Teenage Programmer
E-Mail: [email protected]
ICQ: 19552879
AIM: RYoni69
-
Nov 17th, 1999, 01:09 AM
#2
Hyperactive Member
Yonatan
I don't understand how to make that happen in code. Can you give me some hints:
here is my code:
Private Sub Form_Load()
Dim temp As String
Dim section(300) As String
Dim i, j, newfile As Integer
newfile = FreeFile
Open "c:\temp\9999edcs.txt" For Input As newfile
While Not EOF(newfile)
Line Input #newfile, temp
If InStr(temp, "<") Then
List1.AddItem (section(i))
i = i + 1
Else:
section(i) = section(i) & temp
End If
Wend
Close newfile
End Sub
here is a little of the text file
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
16000 ELECTRICAL SPECIFICATIONS
>010<
DEFINITIONS
BUILDER means Marshall Erdman & Associates.
EC means Electrical Contractor.
FAC means Fire Alarm Contractor.
TC means Telephone Contractor.
CC means Temperature Controls Contractor.
FURNISH means to purchase, deliver to job site, and unload from truck at job site.
INSTALL means to mount in place and make all necessary connections as specified on plans and
shop drawings.
PROVIDE means to FURNISH and INSTALL.
SWITCHGEAR includes all switchboards, motor control centers, panelboards, circuit breakers,
fusible and non-fusible disconnects, fuses, transformers, contactors, starters, etc.
SWITCHGEAR SUPPLIER means either the BUILDER or the EC, as determined by the Project
Manager, based on a separate switchgear bid by the EC.
>020<
GENERAL
>025<
the >***< is the delimiter
thank you for your time and have a good day 
[This message has been edited by badgers (edited 11-17-1999).]
-
Nov 17th, 1999, 12:15 PM
#3
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|