NR
Nandakumar R
Syncfusion Team
August 21, 2009 04:48 AM UTC
Hi,
I regret for the inconvenience caused. Your DirectTrac incident has been updated with the details. There seem to be some issues with the lexem based changes when you try to make one. You can use the following workaround in the uncomment section and achieve this behaviour.
[C#]
private void Form1_Load(object sender, EventArgs e)
{
//Set start and end comment
this.editControl1.LoadFile(@"VBScriptSource.vbs");
this.editControl1.ApplyConfiguration(KnownLanguages.VBNET);
IConfigLanguage lan = this.editControl1.Language;
lan.StartComment = "REM ";
lan.EndComment = "";
}
private void btnComment_Click(object sender, EventArgs e)
{
//Comment
this.editControl1.CommentLine();
}
private void btnUncomment_Click(object sender, EventArgs e)
{
//Uncomment
this.editControl1.UnCommentLine();
string CommentedText = this.editControl1.SelectedText;
CommentedText = CommentedText.Replace(@"REM ", "");
editControl1.SelectedText = CommentedText.Replace(@"REM ", "");
editControl1.SelectionCancel();
}
Regards,
Nanda