Why does not the 'Text' property work like in System.Windows.Forms.TextBox

Topics: User Forum
Jan 29, 2009 at 5:08 PM
Edited Jan 29, 2009 at 5:10 PM
w
Developer
Feb 4, 2009 at 1:28 PM
It works like every Text property, didn't it?

It a normal string so you can access it like every other String property.
What exactly is your problem???
Feb 5, 2009 at 2:35 PM
Edited Feb 6, 2009 at 12:40 PM
Sorry, i works now.

But when i use the TextChanged event it will not work. Fx:

Private Sub Scintilla1_TextChanged(ByVal... ......
       TextBox1.Text = Scintilla1.Text
End Sub

Developer
Feb 5, 2009 at 2:51 PM
I havn't tried your Code because I'm not that good at VB.NET but in my opinion it should work.
The event is a normal Controlevent.

Describe your problem in more detail, I still don't understand it ;-)
Feb 6, 2009 at 12:50 PM
I just mean that the TextChanged event of the Scintilla component doesn't work:

C# Code:
private void scintilla1_TextChanged(object sender, EventArgs e)
        {
            textBox1.Text = scintilla1.Text;
        }


VB 2008 Code:
 
Private Sub Scintilla1_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Scintilla1.TextChanged
        TextBox1.Text = Scintilla1.Text
 End Sub


If someone asked me what would happen if one of theese events was fired i would say that the text in the TextBox1 would be the same as in the Scintilla1, but it doesn't, nothing happens.
Feb 6, 2009 at 9:16 PM

Hi!

I have the same problem.Event TextChanged does'nt work in C#.

Feb 7, 2009 at 11:21 PM
Yes, it seems like TextChanged still don't work. It was discussed there:
http://www.codeplex.com/ScintillaNET/Thread/View.aspx?ThreadId=45625

So, only way is to use DocumentChanged event, only it's not very comfortable, as it's used more then one time when you type one symbol for example.

Coordinator
Feb 8, 2009 at 10:20 PM
I completely agree that the TextChanged event should fire. I've created work item 21053 to address this oversight.


Thanks,
Jacob