Uploaded by howtomakesoftware on Nov 1, 2011
in this tutorial i will show you how to create a form to set a text into the ASCII code and an ASCII code to the text
dutch technology site + forum: http://technetforum.tk/
codes:
set text to code
Dim Val As String = Nothing Dim Result As New System.Text.StringBuilder For Each Character As Byte In System.Text.ASCIIEncoding.ASCII.GetBytes(RichTextBox1.Text) Result.Append(Convert.ToString(Character, 2).PadLeft(8, "0")) Result.Append(" ") Next Val = Result.ToString.Substring(0, Result.ToString.Length - 1) RichTextBox2.Text = Val
set code to text
Dim Val As String = Nothing Dim Characters As String = System.Text.RegularExpressions.Regex.Replace(RichTextBox2.Text, "[^01]", "") Dim ByteArray((Characters.Length / 8) - 1) As Byte For Index As Integer = 0 To ByteArray.Length - 1 ByteArray(Index) = Convert.ToByte(Characters.Substring(Index * 8, 8), 2) Next Val = System.Text.ASCIIEncoding.ASCII.GetString(ByteArray) RichTextBox1.Text = Val
save code
Dim SaveFileDialog1 As New SaveFileDialog SaveFileDialog1.Filter = "Rich Text Files(*.rtf)|*.rtf|All files (*.*)|*.*" SaveFileDialog1.ShowDialog() FileOpen(1, SaveFileDialog1.FileName, OpenMode.Output) PrintLine(1, RichTextBox2.Text) FileClose(1)
save text
Dim SaveFileDialog1 As New SaveFileDialog SaveFileDialog1.Filter = "Rich Text Files(*.rtf)|*.rtf|All files (*.*)|*.*" SaveFileDialog1.ShowDialog() FileOpen(1, SaveFileDialog1.FileName, OpenMode.Output) PrintLine(1, RichTextBox1.Text) FileClose(1)
open code
Dim OpenFileDialog1 As New OpenFileDialog Dim AllText As String = "", LineOfText As String = "" OpenFileDialog1.Filter = "All Files|*.*" OpenFileDialog1.ShowDialog() Try FileOpen(1, OpenFileDialog1.FileName, OpenMode.Input) Do Until EOF(1) LineOfText = LineInput(1) AllText = AllText & LineOfText & vbCrLf Loop RichTextBox2.Text = AllText Catch Finally FileClose(1) End Try
open text
Dim OpenFileDialog1 As New OpenFileDialog Dim AllText As String = "", LineOfText As String = "" OpenFileDialog1.Filter = "All Files|*.*" OpenFileDialog1.ShowDialog() Try FileOpen(1, OpenFileDialog1.FileName, OpenMode.Input) Do Until EOF(1) LineOfText = LineInput(1) AllText = AllText & LineOfText & vbCrLf Loop RichTextBox1.Text = AllText Catch Finally FileClose(1) End Try
-
1 likes, 0 dislikes
10:16
How to make a ASCII Viewer Part2by Deadlyman66308 views
5:00
tutorial 8 visual basic how to create code to set positionby howtomakesoftware23 views
9:25
How to Make ASCII Viewer Part1by Deadlyman66617 views
1:10
Visual Basic 2008 - Keycodesby Surowithekiller4,583 views
4:41
ED - ASCII Code For Fireloch Displayby magidavid148 views
3:04
Using ASCII Character Codesby fahadsikder2,322 views
3:28
Tutorial - How to make names ascii artby CTArbiter243 views
3:26
C++ tutorial 25...The ASCII Character Setby supereasytuts215 views
1:30
♪♫♥ More ASCII ALT- key symbol codes ♥♫♪by holiday34691103,357 views
10:07
Computer Programming Lecture 4 Part 1 of 4 ASCII Codes by Sabih ul Hassanby sabihlectures495 views
30:36
Visual Basic Game Programming Tutorial - Part 4 - Key Input and Character Movementby Aardaerimus3,565 views
5:54
Binary to ASCII Converterby ComputerMaster1st1,133 views
4:11
VBScript(Tutorial) Character Counterby stupidgaylogincrap4,257 views
6:21
Example of Keydown & Keypress by VISION TECHNOLOGY SERVICEby VisionTechnnology1,256 views
0:36
Alt + Num Pad Symbolsby HardHittingRoad321122,830 views
0:26
Change Name on Yahoo Mailby lougonzo5,237 views
2:40
tutorial 7 visual basic how to switch formsby howtomakesoftware14 views
0:02
Second Life ASCII Translatorby apocolyp4220 views
7:21
chapter 11: File input output (Hindi / English)by learnbywatch8,760 views
- Loading more suggestions...
Link to this comment:
All Comments (0)