Visual Basic Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreVisual Basic Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old April 3rd, 2003, 10:55 PM
digitsnake's Avatar
digitsnake digitsnake is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Sep 2002
Location: Orlando FL
Posts: 130 digitsnake User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 7
Send a message via Yahoo to digitsnake
Question how to display text files

Hi all,

I am new to VB. Please give me couple pointers.

Is there object for displaying text file with scroll bar?

Related questions would be how do I display multiple lines in the TextBox? Not wrap lines... actually two seperated lines. I know I can't do "\n".

Thanks
__________________
Help me, help you, help others...

Reply With Quote
  #2  
Old April 4th, 2003, 07:49 AM
Onslaught's Avatar
Onslaught Onslaught is offline
/(bb|[^b]{2})/
Dev Shed Demi-God (4500 - 4999 posts)
 
Join Date: Nov 2001
Location: Somewhere in the great unknown
Posts: 4,840 Onslaught User rank is Second Lieutenant (5000 - 10000 Reputation Level)Onslaught User rank is Second Lieutenant (5000 - 10000 Reputation Level)Onslaught User rank is Second Lieutenant (5000 - 10000 Reputation Level)Onslaught User rank is Second Lieutenant (5000 - 10000 Reputation Level)Onslaught User rank is Second Lieutenant (5000 - 10000 Reputation Level)Onslaught User rank is Second Lieutenant (5000 - 10000 Reputation Level)Onslaught User rank is Second Lieutenant (5000 - 10000 Reputation Level) 
Time spent in forums: 2 Days 36 m 16 sec
Reputation Power: 88
Send a message via ICQ to Onslaught
The easiest way would be to put the text in a richtextbox control and use it.
To get the scrollbars on it use it's "scrollbars" property.
i.e.
RichTextBox1.ScrollBars = rtfBoth

To get line feeds instead of using "\n" use vbCrLf which is the vb constant for carriage return & line feed.

Reply With Quote
  #3  
Old April 4th, 2003, 09:43 AM
digitsnake's Avatar
digitsnake digitsnake is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Sep 2002
Location: Orlando FL
Posts: 130 digitsnake User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 7
Send a message via Yahoo to digitsnake
Thank you Onslaught

Reply With Quote
  #4  
Old April 7th, 2003, 02:51 AM
Deep Code Deep Code is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2002
Location: Massachusetts
Posts: 32 Deep Code User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 23 m 2 sec
Reputation Power: 6
Send a message via AIM to Deep Code
vbCrLf!

text1.text = "foo" & vbCrLf & "bar"

there ya go
__________________
User1: Is September 11th the first time the market ever bombed?
Me: ... *slaps user1* great depression, idiot.
User1: What was that?
Join Darkscape!



Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreVisual Basic Programming > how to display text files


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway
Stay green...Green IT