Tabbed Notepad
Heres your chance to share your own tutorials with the community. Just post them on here. If your lucky they may even be posted on the main site.
8 posts
Page 1 of 1
Hello Guys
This is my first Tutorial hope you learn how to make tabbed notepad
ok lets start
-Create A new Project Name it what you want
-Add 6 Buttons ( New , Remove , Open , Save As... , Font , Color ) And 1 Tabcontrol
it will look like this.
![Image]()
Note : you can use MenuStrip or Toolbar but i choose button .
-Remove Tabpages
![Image]()
And here is the codes !
Dont forget to put Dim A As Integer = 1 or it won't work ( UNDER PUPLIC CLASS FORM )
Hope you like my first tut !
This is my first Tutorial hope you learn how to make tabbed notepad
ok lets start
-Create A new Project Name it what you want
-Add 6 Buttons ( New , Remove , Open , Save As... , Font , Color ) And 1 Tabcontrol
it will look like this.

Note : you can use MenuStrip or Toolbar but i choose button .
-Remove Tabpages

And here is the codes !
Dont forget to put Dim A As Integer = 1 or it won't work ( UNDER PUPLIC CLASS FORM )
Code: Select all
You Can Use the normal Richtextbox Codes on this like :
Puplic Class Form1 :
Dim A As Integer = 1
------------------------
Add Tab :
Dim RTB As New RichTextBox
TabControl1.TabPages.Add(1, "Page " & A)
TabControl1.SelectTab(A - 1)
RTB.Dock = DockStyle.Fill
TabControl1.SelectedTab.Controls.Add(RTB)
A = A + 1
------------------------------------------
RemoveTab:
If TabControl1.TabCount = 1 Then
'Do Nothing
Else
TabControl1.TabPages.RemoveAt(TabControl 1.SelectedIndex)
TabControl1.SelectTab(TabControl1.TabPag es.Count - 1)
A = A - 1
End if
----------------------------------------------
Save:
Dim SFD As New SaveFileDialog
SFD.Filter = "Rich Text Files|*.rtf"
SFD.ShowDialog()
FileOpen(1, SFD.FileName, OpenMode.Output)
PrintLine(1, CType(TabControl1.SelectedTab.Controls.Item(0), RichTextBox).Text)
FileClose(1)
-------------------------------------------------
Open:
Dim OPF As New OpenFileDialog
Dim AllText As String = "", LineOfText As String = ""
OPF.Filter = "All Files|*.*"
OPF.ShowDialog()
Try
FileOpen(1, OPF.FileName, OpenMode.Input)
Do Until EOF(1)
LineOfText = LineInput(1)
AllText = AllText & LineOfText & vbCrLf
Loop
CType(TabControl1.SelectedTab.Controls.Item(0), RichTextBox).Text = AllText
Catch
Finally
FileClose(1)
End Try
----------------------------------------------------------
Font:
Dim FS As New FontDialog
FS.ShowDialog()
CType(TabControl1.SelectedTab.Controls.Item(0), RichTextBox).Font = FS.Font
---------
Colour:
Dim FC As New ColorDialog
FC.ShowDialog()
CType(TabControl1.SelectedTab.Controls.Item(0), RichTextBox).ForeColor = FC.Color
---------
Code: Select all
CType(TabControl1.SelectedTab.Controls.Item(0), RichTextBox) = Richtextbox !CType(TabControl1.SelectedTab.Controls.Item(0), RichTextBox).Undo
Hope you like my first tut !
You do not have the required permissions to view the files attached to this post.
Last edited by TheSecretBoy on Thu Dec 02, 2010 9:00 pm, edited 1 time in total.
Code'N'Stuff
TheSecretBoY
Dont forget to give thanks for those helpful posts cooll;
TheSecretBoY
Dont forget to give thanks for those helpful posts cooll;
actually , this is to easy to make and its not really alot of code lol (alot of friggin comments)
I don't think it's really usefull.
I mean, you have Notepad on your computer. Why would anybody else want to download a less intelligent one? :P
iLenkaa
I mean, you have Notepad on your computer. Why would anybody else want to download a less intelligent one? :P
iLenkaa
iLenkaa wrote:I don't think it's really usefull.This is not only used for Notepads idoit;
I mean, you have Notepad on your computer. Why would anybody else want to download a less intelligent one? :P
iLenkaa
you can you this for webbrowsers + many programs hehaho;
--------------------------------------------------------------------------------------------------------------------------------------------
Thanks
Code'N'Stuff
TheSecretBoY
Dont forget to give thanks for those helpful posts cooll;
TheSecretBoY
Dont forget to give thanks for those helpful posts cooll;
TheSecretBoy wrote:I didn't say it wasn't good :P lmao;iLenkaa wrote:I don't think it's really usefull.This is not only used for Notepads idoit;
I mean, you have Notepad on your computer. Why would anybody else want to download a less intelligent one? :P
iLenkaa
you can you this for webbrowsers + many programs hehaho;
--------------------------------------------------------------------------------------------------------------------------------------------
Thanks
I like it. :P
But yeah. I just don't think it's very usefull for something...
I don't think it's really usefull.ILenkaa
I mean, you have Notepad on your computer. Why would anybody else want to download a less intelligent one?
iLenkaa
You have to Remember that this site is for all People with all Levels of Coding, If it makes you feel good designing and coding an app then YES you should PROUDLY show it off

Chris
iLenkaa wrote:I don't think it's really usefull.Dude this is a tutorial for people that is new to programming, don't post these friggin disappointing comments. You should be glad he posted it!
I mean, you have Notepad on your computer. Why would anybody else want to download a less intelligent one? :P
iLenkaa
You wouldn't be glad if someone said that to you i you thought you had posted a wonderful tutorial!
LMAOSHMSFOAIDMT
Laughing my a** of so hard my sombrero fell off and I dropped my taco lmao;
Over 30 projects with source code!
Please give reputation to helpful members!
![Image]()
![Image]()
Laughing my a** of so hard my sombrero fell off and I dropped my taco lmao;
Over 30 projects with source code!
Please give reputation to helpful members!

8 posts
Page 1 of 1
Copyright Information
Copyright © Codenstuff.com 2020 - 2023