Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How can i set Textbox1.text equal to the conents of file.txt?
#1
How can i set Textbox1.text equal to the conents of file.txt?
Reply
#2
Could you please tell us what language this is for?
Reply
#3
well depends dude cause where is file.txt going to be and whats in it?
Reply
#4
(11-12-2009, 11:52 PM)Fail Ninja Wrote: Could you please tell us what language this is for?

Sorry thought it was obvious being in the visual basic section, but yeah, visual basic.
Reply
#5
Well it could have being VB.Net aswell.
Reply
#6
Its a vb.net AND other .net language section ;)
Reply
#7
Double post -.-

http://www.supportforums.net/showthread.php?tid=2838
Reply
#8
(11-14-2009, 04:05 PM)TechMan8 Wrote: Double post -.-

http://www.supportforums.net/showthread.php?tid=2838

No, This thread is different, he is asking how to read from a .txt not write to it.
Reply
#9
7 posts and no one helped him, wow you guys......

I didn't tested this as I don't have need tools for testings.
But I'm sure it's what you are looking for.

Code:
f = FreeFile
path = App.Path & "\file.txt"

Open path For Input As f
    TextBox1.Text = Input(Lof(f), f)
Close f
Reply
#10
TextBox1.Text = My.Computer.FileSystem.ReadAllText("filepathname")

This will solvs ur problem..(LOL)
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  [NEED HELP] how to read a text file and import to listview vb.net w00pz 7 5,845 02-13-2012, 06:42 AM
Last Post: AceInfinity
  TextBox2.Text | Transfer Text to ListBox Die 3 2,398 01-02-2012, 06:09 PM
Last Post: AceInfinity
  How to set a textbox's value [VB] James Ford 10 2,088 09-01-2011, 02:15 AM
Last Post: James Ford
  Text Converter. Turn your text upside down! Red X 29 7,202 08-01-2011, 07:46 AM
Last Post: Red X
  [HELP] Open and save txt file to the internet. w00pz 5 1,310 05-29-2011, 01:34 PM
Last Post: w00pz

Forum Jump:


Users browsing this thread: 1 Guest(s)