Page 1 of 2 12 LastLast
Results 1 to 15 of 22
  1. #1
    steveroseik's Avatar
    Join Date
    Sep 2011
    Gender
    male
    Location
    Earth
    Posts
    463
    Reputation
    50
    Thanks
    2,114

    Vb Code READER !

    I Need to Make a Vb COde Reader Like
    I Type in text box And if I Opened Quotes " it Changes to Brown "
    and when i type Dim it gets blue
    'and so on !

    How Can I Make This In a Textbox or richtextbox ?





    Since 10th Of September 2013



    Facebook : Steve Roseiik
    Twitter : Steveroseik
    Kik : steveroseik
    Instagram : steveroseik

  2. #2
    Jorndel's Avatar
    Join Date
    Jul 2010
    Gender
    male
    Location
    Norway
    Posts
    8,676
    Reputation
    905
    Thanks
    19,113
    My Mood
    Angelic
    Syntax Highlighter is what you're after

    There are many tutorials on how to make "nooby" ones.
    >C++ is more the way to go for making such 'custom' controls for such support.

    But there is some options you can look at.

    The 'easy' and simple but also a nooby way. (IMO)
    -But I can't think of anything else now so...

    Would be the mark the text, color it. Then continue the progress for each find of the word.
    >Would be very slow and take much resources.

    (I'll look around to see if I can find something to help you )

     
    Contributor 01.27.2012 - N/A
    Donator 07-17-2012 - Current
    Editor/Manager 12-16-12 - N/A
    Minion 01-10-2013 - 07.17.13
    Former Staff 09-20-2012 - 01-10-2013 / 07-17-2013 - Current
    Cocksucker 20-04-2013 - N/A

  3. #3
    Threadstarter
    ♢♏ - Σxperτ Ѵß Coder †
    Premium Member
    steveroseik's Avatar
    Join Date
    Sep 2011
    Gender
    male
    Location
    Earth
    Posts
    463
    Reputation
    50
    Thanks
    2,114
    Quote Originally Posted by Jorndel View Post
    Syntax Highlighter is what you're after

    There are many tutorials on how to make "nooby" ones.
    >C++ is more the way to go for making such 'custom' controls for such support.

    But there is some options you can look at.

    The 'easy' and simple but also a nooby way. (IMO)
    -But I can't think of anything else now so...

    Would be the mark the text, color it. Then continue the progress for each find of the word.
    >Would be very slow and take much resources.

    (I'll look around to see if I can find something to help you )
    SERIOUSLY !! ThanQ So Much !!
    i need Something with visual basic If u can !!





    Since 10th Of September 2013



    Facebook : Steve Roseiik
    Twitter : Steveroseik
    Kik : steveroseik
    Instagram : steveroseik

  4. #4
    Jorndel's Avatar
    Join Date
    Jul 2010
    Gender
    male
    Location
    Norway
    Posts
    8,676
    Reputation
    905
    Thanks
    19,113
    My Mood
    Angelic
    Quote Originally Posted by steveroseik View Post
    SERIOUSLY !! ThanQ So Much !!
    i need Something with visual basic If u can !!
    Google is your friend:

    It's in C# but C# & VB is mainly the same language. (Just a very different syntax and some more stuff)
    But you will get the idea of it so...
    Fast Colored TextBox for Syntax Highlighting - CodeProject
    Last edited by Jorndel; 03-31-2013 at 12:14 PM.

     
    Contributor 01.27.2012 - N/A
    Donator 07-17-2012 - Current
    Editor/Manager 12-16-12 - N/A
    Minion 01-10-2013 - 07.17.13
    Former Staff 09-20-2012 - 01-10-2013 / 07-17-2013 - Current
    Cocksucker 20-04-2013 - N/A

  5. #5
    Threadstarter
    ♢♏ - Σxperτ Ѵß Coder †
    Premium Member
    steveroseik's Avatar
    Join Date
    Sep 2011
    Gender
    male
    Location
    Earth
    Posts
    463
    Reputation
    50
    Thanks
    2,114
    Quote Originally Posted by Jorndel View Post


    Google is your friend:

    It's in C# but C# & VB is mainly the same language. (Just a very different syntax and some more stuff)
    But you will get the idea of it so...
    Fast Colored TextBox for Syntax Highlighting - CodeProject
    Can You COnvert it to VB or Tell Me The IDEA Cause I Don't know anything about C#





    Since 10th Of September 2013



    Facebook : Steve Roseiik
    Twitter : Steveroseik
    Kik : steveroseik
    Instagram : steveroseik

  6. #6
    LilGho$t's Avatar
    Join Date
    Nov 2011
    Gender
    male
    Posts
    419
    Reputation
    9
    Thanks
    330
    My Mood
    Twisted
    How retarded is this guy?

  7. #7
    Threadstarter
    ♢♏ - Σxperτ Ѵß Coder †
    Premium Member
    steveroseik's Avatar
    Join Date
    Sep 2011
    Gender
    male
    Location
    Earth
    Posts
    463
    Reputation
    50
    Thanks
    2,114
    Quote Originally Posted by LilGho$t View Post
    How retarded is this guy?
    What do u Mean ?!

    ---------- Post added at 06:39 PM ---------- Previous post was at 06:38 PM ----------

    The Whole idea is to make a Vb.net Code Viewer or reader or editor !!





    Since 10th Of September 2013



    Facebook : Steve Roseiik
    Twitter : Steveroseik
    Kik : steveroseik
    Instagram : steveroseik

  8. #8
    Vibrations's Avatar
    Join Date
    Jan 2013
    Gender
    male
    Location
    Everywhere and everything at once, I am you and you are me, we are the same ~
    Posts
    505
    Reputation
    26
    Thanks
    110
    Quote Originally Posted by steveroseik View Post
    What do u Mean ?!

    ---------- Post added at 06:39 PM ---------- Previous post was at 06:38 PM ----------

    The Whole idea is to make a Vb.net Code Viewer or reader or editor !!

    Code Converter | Provided by Telerik

  9. #9
    Threadstarter
    ♢♏ - Σxperτ Ѵß Coder †
    Premium Member
    steveroseik's Avatar
    Join Date
    Sep 2011
    Gender
    male
    Location
    Earth
    Posts
    463
    Reputation
    50
    Thanks
    2,114
    Quote Originally Posted by Conceitful View Post
    What Should I Do With ThiS ?!





    Since 10th Of September 2013



    Facebook : Steve Roseiik
    Twitter : Steveroseik
    Kik : steveroseik
    Instagram : steveroseik

  10. #10
    Vibrations's Avatar
    Join Date
    Jan 2013
    Gender
    male
    Location
    Everywhere and everything at once, I am you and you are me, we are the same ~
    Posts
    505
    Reputation
    26
    Thanks
    110
    Quote Originally Posted by steveroseik View Post
    What Should I Do With ThiS ?!
    Use ur brain... Convert the c# code the guy posted above to vb.net

    PLEASE USE THE NOGGIN OF WISDOM

  11. #11
    Threadstarter
    ♢♏ - Σxperτ Ѵß Coder †
    Premium Member
    steveroseik's Avatar
    Join Date
    Sep 2011
    Gender
    male
    Location
    Earth
    Posts
    463
    Reputation
    50
    Thanks
    2,114
    Quote Originally Posted by Conceitful View Post
    Use ur brain... Convert the c# code the guy posted above to vb.net

    PLEASE USE THE NOGGIN OF WISDOM
    I Had Tried This !! it Just Created a Class The Makes a New SyntaxRichTextBox That Change The Color Of The Numbers and Quotes ONLY !!

    I Have This Code :
    Code:
          Dim words As List(Of String) = New List(Of String)(New String() {"AddHandler", _
    "AddressOf", _
    "Alias", _
    "And", _
    "AndAlso", _
          "Ansi", _
    "As", _
            "Assembly", _
           " Auto", _
    "Boolean", _
    "ByRef", _
    "Byte", _
    "ByVal", _
    "Call", _
    "Case", _
    "Catch", _
    "CBool", _
    "CByte", _
    "CChar", _
    "CDate", _
    "CDec", _
    "CDbl", _
    "Char", _
    "CInt", _
    "Class", _
    "CLng", _
    "CObj", _
    "Const", _
    "CShort", _
    "CSng", _
    "CStr", _
    "CType", _
    "Date", _
    "Decimal", _
    "Declare", _
    "Default", _
    "Delegate", _
    "Dim", _
    "DirectCast", _
    "Do", _
    "Double", _
    "Each", _
    "Else", _
    "ElseIf", _
    "End", _
    "Enum", _
    "Erase", _
    "Error", _
    "Event", _
    "Exit", _
    "False", _
    "Finally", _
    "For", _
    "Friend", _
    "Function", _
    "Get", _
    "GetType", _
    "GoSub", _
    "GoTo", _
    "Handles", _
    "If", _
    "Implements", _
    "Imports", _
    "In", _
    "Inherits", _
    "Integer", _
    "Interface", _
    "Is", _
    "Let", _
    "Lib", _
    "Like", _
    "Long", _
    "Loop", _
    "Me", _
    "Mod", _
    "Module", _
    "MustInherit", _
    "MustOverride", _
    "MyBase", _
    "MyClass", _
    "Namespace", _
    "New", _
    "Next", _
    "Not", _
    "Nothing", _
    "NotInheritable", _
    "NotOverridable", _
    "Object", _
    "On", _
    "Option", _
    "Optional", _
    "Or", _
    "OrElse", _
    "Overloads", _
    "Overridable", _
    "Overrides", _
    "ParamArray", _
    "Preserve", _
    "Private", _
    "Property", _
    "Protected", _
    "Public", _
    "RaiseEvent", _
    "ReadOnly", _
    "ReDim", _
     "REM", _
    "RemoveHandler", _
    "Resume", _
    "Return", _
    "Select", _
    "Set", _
    "Shadows", _
    "Shared", _
    "Short", _
    "Single", _
    "Static", _
    "Step", _
    "Stop", _
    "String", _
    "Structure", _
    "Sub", _
    "SyncLock", _
    "Then", _
     "Throw", _
    "To", _
    "True", _
     "Try", _
    "TypeOf", _
      "Unicode", _
      "Until", _
    "Variant", _
    "When", _
    "While", _
    "With", _
    "WithEvents", _
    "WriteOnly", _
    "Xor", _
    "#Const", _
    "#ExternalSource", _
    "#If...Then...#Else", _
    "#Region"})
    Tell Me How to :
    Code:
    If The Richtextbox contains any of the list above then
    change color to blue
    ANYONE COULD HELP ?!!





    Since 10th Of September 2013



    Facebook : Steve Roseiik
    Twitter : Steveroseik
    Kik : steveroseik
    Instagram : steveroseik

  12. #12
    Pingo's Avatar
    Join Date
    Apr 2010
    Gender
    male
    Posts
    687
    Reputation
    24
    Thanks
    865
    My Mood
    Blah
    Can you code in vb? If so, how long.
    Have a go at it and see what you come up with.
    Just check the string to see if it contains any of the keywords,
    get it's location/length in the string and change the color.

  13. #13
    Threadstarter
    ♢♏ - Σxperτ Ѵß Coder †
    Premium Member
    steveroseik's Avatar
    Join Date
    Sep 2011
    Gender
    male
    Location
    Earth
    Posts
    463
    Reputation
    50
    Thanks
    2,114
    Quote Originally Posted by Pingo View Post
    Can you code in vb? If so, how long.
    Have a go at it and see what you come up with.
    Just check the string to see if it contains any of the keywords,
    get it's location/length in the string and change the color.
    Give Me The Code !!





    Since 10th Of September 2013



    Facebook : Steve Roseiik
    Twitter : Steveroseik
    Kik : steveroseik
    Instagram : steveroseik

  14. #14
    Jorndel's Avatar
    Join Date
    Jul 2010
    Gender
    male
    Location
    Norway
    Posts
    8,676
    Reputation
    905
    Thanks
    19,113
    My Mood
    Angelic
    Quote Originally Posted by steveroseik View Post
    Give Me The Code !!
    We're not here to spoon feed you.
    We're here to help you, not to give you something that you can Copy & Paste.

    >Then we could just have made it ourselves...

     
    Contributor 01.27.2012 - N/A
    Donator 07-17-2012 - Current
    Editor/Manager 12-16-12 - N/A
    Minion 01-10-2013 - 07.17.13
    Former Staff 09-20-2012 - 01-10-2013 / 07-17-2013 - Current
    Cocksucker 20-04-2013 - N/A

  15. The Following User Says Thank You to Jorndel For This Useful Post:

    Pingo (04-02-2013)

  16. #15
    Threadstarter
    ♢♏ - Σxperτ Ѵß Coder †
    Premium Member
    steveroseik's Avatar
    Join Date
    Sep 2011
    Gender
    male
    Location
    Earth
    Posts
    463
    Reputation
    50
    Thanks
    2,114
    Quote Originally Posted by Jorndel View Post


    We're not here to spoon feed you.
    We're here to help you, not to give you something that you can Copy & Paste.

    >Then we could just have made it ourselves...
    That was So Helpful -.-

    ---------- Post added at 08:54 PM ---------- Previous post was at 07:45 PM ----------

    I Made It !!
    Code:
    If RichTextBox1.Text.Length > 0 Then
                Dim selectStart As Integer = RichTextBox1.SelectionStart
                RichTextBox1.Select(0, RichTextBox1.Text.Length)
                RichTextBox1.SelectionColor = Color.Black
                RichTextBox1.DeselectAll()
                For Each oneWord As String In words
                    Dim pos As Integer = 0
                    Do While RichTextBox1.Text.ToUpper.IndexOf(oneWord.ToUpper, pos) >= 0
                        pos = RichTextBox1.Find(oneWord.ToUpper, RichTextBoxFinds.WholeWord)
                        RichTextBox1.Select(pos, oneWord.Length)
                        RichTextBox1.SelectionColor = Color.Blue
                        pos += 1
                    Loop
                Next
                RichTextBox1.SelectionStart = selectStart
                RichTextBox1.SelectionLength = 0
            End If
    But I'm Facing a New Problem Right Now !
    When I Start Typing Manually it Works Fine !!
    But When I Paste a Whole Code This Error Pops Up !

    And I Got This Other Code :
    Code:
       Dim rx As New Regex("AddHandler |AddressOf |Alias |And |AndAlso |Ansi |As |Assembly |Auto |Boolean |ByRef |Byte |" + _
    "ByVal |Call |Case |Catch |CBool |CByte |CChar |CDate |CDec |CDbl |Char |CInt |Class |CLng |CObj |Const |CShort |CSng |" + _
    "CStr |CType |Date |Decimal |Declare |Default |Delegate |Dim |DirectCast |Do |Double |Each |Else |ElseIf |End |Enum |" + _
    "Erase |Error |Event |Exit |False |Finally |For |Friend |Function |Get |GetType |GoSub |GoTo |Handles |If |Implements |Imports |" + _
    "In |Inherits |Integer |Interface |Is |Let |Lib |Like |Long |Loop |Me |Mod |Module |MustInherit |MustOverride |MyBase |" + _
    "MyClass |Namespace |New |Next |Not |Nothing |NotInheritable |NotOverridable |Object |On |Option |Optional |Or |OrElse |" + _
    "Overloads |Overridable |Overrides |ParamArray |Preserve |Private |Property |Protected |Public |RaiseEvent |ReadOnly |ReDim |" + _
    "REM |RemoveHandler |Resume |Return |Select |Set |Shadows |Shared |Short |Single |Static |Step |Stop |String |Structure |Sub |" + _
    "SyncLock |Then |Throw |To |True |Try |TypeOf |Unicode |Until |Variant |When |While |With |WithEvents |WriteOnly |Xor |#Const |#ExternalSource |#If...Then...#Else |#Region |")
            For Each m As Match In rx.Matches(RichTextBox1.Text)
                RichTextBox1.SelectionStart = m.Index
                RichTextBox1.SelectionLength = m.Value.Length
                RichTextBox1.SelectionColor = Color.Blue
            Next
            rx = New Regex(""".+""")
            For Each m As Match In rx.Matches(RichTextBox1.Text)
                RichTextBox1.SelectionStart = m.Index
                RichTextBox1.SelectionLength = m.Value.Length
                RichTextBox1.SelectionColor = Color.Tomato
            Next
    It Works So Fine With Pasting The Whole COde !
    How to Make an "IF" Code which gives this Meaning :
    Code:
    If paste function occured then
    generate the second code
    esle
    generate the first code
    AND I'M ON THE RichTextBox.textChanged Sub





    Since 10th Of September 2013



    Facebook : Steve Roseiik
    Twitter : Steveroseik
    Kik : steveroseik
    Instagram : steveroseik

Page 1 of 2 12 LastLast

Similar Threads

  1. Replies: 37
    Last Post: 06-20-2006, 04:24 PM
  2. Pre-Regerstration - E3 Codes
    By Dave84311 in forum WarRock - International Hacks
    Replies: 67
    Last Post: 06-13-2006, 08:06 AM
  3. hi can any1 help me make or find a cheat code
    By CrUsHa in forum WarRock - International Hacks
    Replies: 3
    Last Post: 05-19-2006, 04:39 PM
  4. a Couple WPE Weapon codes?
    By phil823 in forum WarRock - International Hacks
    Replies: 16
    Last Post: 02-10-2006, 02:14 PM