Text Editor in VB for beginners - Printable Version +- Support Forums (https://www.supportforums.net) +-- Forum: Categories (https://www.supportforums.net/forumdisplay.php?fid=87) +--- Forum: Coding Support Forums (https://www.supportforums.net/forumdisplay.php?fid=18) +---- Forum: Visual Basic and the .NET Framework (https://www.supportforums.net/forumdisplay.php?fid=19) +---- Thread: Text Editor in VB for beginners (/showthread.php?tid=20176) Pages:
1
2
|
Text Editor in VB for beginners - Phoenix - 07-03-2011 Hey everybody i just thought that i would make a tutorial on how to make an advanced text editor in Visual BasicBiggrin. ATTENTION Basic knowledge of the VB GUI is recommend. Ok so first off open up VB and click on new windows forms application and name it (whatever you want to name you text editor). Ok so know that we have that done re size the form to the size that you want it to be and disable the Show Icon feature or use one of your own. know name the name of the form to (the name of you editor). Know go the the toolbox menu and add a tool strip menu. In the tool strip menu make the first box called File and then add some more sub menus as follows. New Open Save Save as.. Text To Speech that's all that will be included in the File menu. Now add another menu to the left of it called Edit and in edit add this Undo Redo Cut Copy Paste Select all That's all for this menu Next menu will be called Format in Format add these sub menus Font in font make another menu going out the side called Type and also include color. and Background under neath Font That's all for Format Those are the Menus in the menu strip. Know in the form add a Text box and fill the rest of the free space and know you have the GUI of your text editor know for the coding yeahRoflmao OK know the code for New in the menu will be as follows: Code: TextBox1.Text() = "" OK the code for Open in the menu strip will be as follows: Code: Dim alltext As String = "", lineoftext As String The code for save will be: Code: Dim save As New System.IO.StreamWriter("E:\settings\PW.urs") Code: SaveFileDialog1.Filter = "txt (*.txt) |*.txt" Code: Dim AB As New PrintDialog The code for Text To Speech will be: Code: Dim SAPI Code: TextBox1.Undo() Code: TextBox1.Redo() Code: Richtextbox1.copy() Code: TexBox1.Paste() Code: TextBox1.Selectall() Code: Dim FS As New FontDialog Code: Dim FC As New ColorDialog Code: Try RE: Text Editor in VB for beginners - Firetech - 07-03-2011 Pictures always help beginners RE: Text Editor in VB for beginners - bckc - 07-04-2011 Remember to include hotkeys, you havn't added that. E.g. ctrl-v for paste ctrl-c for copy etc RE: Text Editor in VB for beginners - AceInfinity - 07-04-2011 Here's my coded example of an advanced notepad that I created around a month ago. Still developing it. They are all the same thing, just with different modifications, and names. A good list of the features is available through all the posts on the second link. I have encryption, find, tabs, and everything saves to a configuration file that can be loaded from later on "config.ini". http://www.supportforums.net/showthread.php?tid=20191 http://www.supportforums.net/showthread.php?tid=18886 RE: Text Editor in VB for beginners - Coding Support - 07-23-2011 This can be very helpful for beginners, but i wanted to say to whoever is going to use this to learn, try to actually understand the code and not just Copy/Paste.. RE: Text Editor in VB for beginners - AceInfinity - 07-23-2011 If anyone requests a class to read from a configurable ini file, i'll release that later. Completely customized by myself for Setting names and Values, also with a comment or titlespace. RE: Text Editor in VB for beginners - PURP - 07-24-2011 This looks good I am sure beginners could use this. RE: Text Editor in VB for beginners - Kyle FYI™ - 07-26-2011 Nice tut could help out a lot of people. RE: Text Editor in VB for beginners - Phoenix - 07-28-2011 Thanks for all the positive comments everybody appreciate although im not in VB development any more me and a group of people are working on a 3D game so im moving onto other languages like C# C++ and Java. RE: Text Editor in VB for beginners - AceInfinity - 07-28-2011 (07-28-2011, 07:37 PM)RP Deliverance Wrote: Thanks for all the positive comments everybody appreciate although im not in VB development any more me and a group of people are working on a 3D game so im moving onto other languages like C# C++ and Java. "VB" and "VB.net" are different. You can still do C#, and C++ in VB. |