Title says it all, I want to put a .txt files TEXT into a Dimmed String. How? Dim TempStorage As String TempStorage = FilePath.Text.ReadAllText Something like that?
Remember to rate posts with the button on the left() - - - - - - - - - - - - - Useful Links:.NET Framework Class Library | Auto Clicker | 30 Minute Regex Tutorial | Visual Basic CodeBank(ALL):Simulate Mouse Click | EaseInstaller | Signs + Description | Read/Write .INI Files | Movable Form Without Titlebar | Check ifFirstRun | Create App Thread | Volume Control Class | Custom Wait Function | Emcranks Auto Updater | System-Wide Hotkeys [Virtual Key Codes] | Get Filename From Download URL | Zipping/Unzipping Using Shell32.dll | Import My.Settings From Previous Build | WebBrowser Control: Delete History | Simple Sound Recorder [mciSendString Commands] | App Trial Code | WebBrowser Control: Get Favicon.ico | Generate Random String | Manipulate Files Using Wildcards |
To read the file into a string that is not an array you call ReadAllText. If you want an array you call ReadAllLines. vb.net Code: Dim textContents As String = IO.File.ReadAllText("C:\path\file.txt")
Dim textContents As String = IO.File.ReadAllText("C:\path\file.txt")
Links: Google | MSDN (Microsoft Documentation) | xkcd Code Bank: VB Submissions | C# Submissions
thanks
Forum Rules