[VB.Net] CodeSyntax - BBcode Syntax Highlighter v1.0 05-31-2011, 10:08 AM
#1
CodeSyntax - BBcode Syntax Highlighter v1.0
![[Image: cSGwF.png]](http://i.imgur.com/cSGwF.png)
![[Image: cSGwF.png]](http://i.imgur.com/cSGwF.png)
Info:
CodeSyntax is a BBcode highlighter for languages like VB.Net and C#.
Since we do not have codeblock for programming languages and [php] codeblock looks confusing to recreate, I made this for syntax highlighting.
You can probably fool the program in one way or the other if you look carefully, so don't get too over-excited and shout "BUGGY" on top of your lungs. Just post here and I'll try to fix them.

Input:
Code:
If ArrLines(intL).Contains("//") AndAlso ArrLines(intL).Contains("""//""") = False Then
ArrWords(intW) = "[color=#32CD32]" & ArrWords(intW) & "[/color]"
Else
If My.Resources.csharpSyntax.Contains(ArrWords(intW)) Then
ArrWords(intW) = "[color=#87CEEB]" & ArrWords(intW) & "[/color]"
'Else
' ArrWords(intW) = ArrWords(intW)
End If
End If
Output:
If ArrLines(intL).Contains("//") AndAlso ArrLines(intL).Contains("""//""") = False Then
ArrWords(intW) = "[color=# 32CD32]" & ArrWords(intW) & "[/ color]"
Else
If My.Resources.csharpSyntax.Contains(ArrWords(intW)) Then
ArrWords(intW) = "[color=# 87CEEB]" & ArrWords(intW) & "[/ color]"
'Else
' ArrWords(intW) = ArrWords(intW)
End If
End If
[link=http://hotfile.com/dl/119439886/9a59567/CodeSyntax.exe.html]![[Image: Download.png]](http://c.imagehost.org/0663/Download.png)
CodeSyntax - BBcode Syntax Highlighter v1.0 (69 Kb)
[/link]
![[Image: Download.png]](http://c.imagehost.org/0663/Download.png)
CodeSyntax - BBcode Syntax Highlighter v1.0 (69 Kb)
[/link]
Spoiler: Source
Note:
Tabs and spaces in code are not preserved since no current MyBB codeblock provides blank space preservation other than [code] ( it ignores every BBcode so it doesn't matter).
This is a huge problem and a big code output from CodeSyntax looks confusing without blank spaces. Unfortunately nothing can be done for it currently.
![[Image: rytwG00.png]](http://i.imgur.com/rytwG00.png)
Redcat Revolution!