Solved

VB.NET RTB Syntax highligting.

Posted on 2003-11-28
12
609 Views
Last Modified: 2008-03-17
Any suggestion on syntax highlighting in vb.net utilizing a rtb?

Preferable read keywords, comments etc from a db or xml file, and do fairly quickly. The keywords and comments etc need to be in a db or xml or the like so the keyword list can grow and expand with different languages. I have gotten several ways to work ok, but they seem slow compared to simular things I have used. This would be more of a cut and paste, highlight, and possible a highlight while typing.


Thanks
0
Comment
Question by:flosoft
  • 5
  • 4
  • 2
  • +1
12 Comments
 
LVL 19

Expert Comment

by:Desp
ID: 9841549
0
 
LVL 19

Expert Comment

by:Desp
ID: 9841566
0
 

Author Comment

by:flosoft
ID: 9841689
Looked at them, I am more looking for a decent start to highlighting like the VB6 or VS.Net does with code syntax, keywords etc.


Thanks.
0
 
LVL 1

Expert Comment

by:RussGreen
ID: 9843112
0
 

Author Comment

by:flosoft
ID: 9843960
No source for how it is done and when pasting in a module's code it seems a bit slow, nice example. Might work and be nice if I could see the source code. guess I'll raise the points to 400.
0
 
LVL 1

Expert Comment

by:RussGreen
ID: 9844747
the source is in the workspace. go back to here http://workspaces.gotdotnet.com/codebox and following the link to source control. You might need to apply to join the workspace, thats fine.

It is slow cause there is a big and it colourizes too many times. I'm not happy which is why there is a workspace for it to get some other interested people involved in improving it.

Russ
0
3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

 
LVL 1

Expert Comment

by:RussGreen
ID: 9844751
0
 
LVL 1

Accepted Solution

by:
RussGreen earned 400 total points
ID: 9844757
The page where you'll be able to get the source code is here...

http://www.gotdotnet.com/Community/Workspaces/fileshare.aspx?id=f012498f-29f8-4e9c-8608-74db65f463fb

Russ
0
 

Author Comment

by:flosoft
ID: 9845319
Got the code, I am playing with it a bit trying to implement it in a usercontrol so it can be dropped onto a form, rather than coding it in, once I get that done, I'll see what I can do on performance.

I am still looking a bit for a regex or faster way...wonder how vb and vs do it so fast?
0
 
LVL 1

Expert Comment

by:RussGreen
ID: 9845554
it is in a user control? the project will compile into codebox.dll

Will you join the workspace and share your findings?

Russ
0
 

Author Comment

by:flosoft
ID: 9846541
If I make any significant changes, I will share them there and post them here, at the moment I am experimenting parsing with regular expressions and using an xml file to store the keywords which is a complete departure from codebox. It seems that perhaps the fastest way would be to write the raw rtf to file on the fly and then load it into a richtextbox, it makes a hard disk hit, but is real quick. Anyways, just a few idea's going on until maybe someone on here can post some code that already is fast at doing this.
0
 
LVL 96

Expert Comment

by:Bob Learned
ID: 10279728
No comment has been added lately, so it's time to clean up this TA.
I will leave the following recommendation for this question in the Cleanup topic area:

Accept: RussGreen {http:#9844757}

Please leave any comments here within the next seven days.
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

TheLearnedOne
EE Cleanup Volunteer
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Welcome my friends to the second instalment and follow-up to our Minify and Concatenate Your Scripts and Stylesheets (http://www.experts-exchange.com/Programming/Languages/.NET/ASP.NET/A_4334-Minify-and-Concatenate-Your-Scripts-and-Stylesheets.html)…
This document covers how to connect to SQL Server and browse its contents.  It is meant for those new to Visual Studio and/or working with Microsoft SQL Server.  It is not a guide to building SQL Server database connections in your code.  This is mo…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

932 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now