Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

print a seq file to a vert scroll textbox

Posted on 1998-06-05
4
238 Views
Last Modified: 2010-05-03
what is the code to print the ENTIRE seq file to a vert scroll textbox. Seq is on 'B' drive and the textbox is on the 'c' drive
I was given this one line code but I do not understand it .
'text1.text = input (LOF(f), f)  . What is the 'f'
0
Comment
Question by:hjaycox
  • 2
4 Comments
 

Author Comment

by:hjaycox
ID: 1462667
Edited text of question
0
 
LVL 5

Accepted Solution

by:
bin_huwairib earned 50 total points
ID: 1462668
hjaycox,

Check the following example.

Example
=======

1- Add form1 to project1.
2- Add command1 to form1.
3- Add textbox1 to form1 and set MultiLine property to True.
4- Paste this code:

Private Sub Command1_Click()
 Dim txt As String
 
 Open "b:\test.txt" For Binary As #1  'replace test.txt with your file name
 txt = Space(LOF(1))
 Get #1, 1, txt
 Text1.Text = txt
 Close #1
End Sub


Best regards
Bin Huwairib
0
 

Expert Comment

by:tell
ID: 1462669
"f" is simply your filehandle
try:
Open "filename.txt" For Input As #1
    Text1.Text = Input(LOF(1), 1)
Close #1
0
 

Author Comment

by:hjaycox
ID: 1462670
excellent....thank you
0

Featured Post

Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
bit defender blocks good applications 2 101
Best way to parse out a json string in VB6? 10 220
Adding to a VBA? 6 77
Collapse and expand table in Word 2010 2 32
Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

856 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