thielj / MetroFramework

Metro UI of Windows 8 for .NET Windows Forms applications
http://thielj.github.io/MetroFramework
Other
396 stars 225 forks source link

Overflow when changing cursor in MetroTextBox #32

Open gishac opened 10 years ago

gishac commented 10 years ago

Try to change the cursor in a MetroTextBox in design or runtime and the application will crash.

DannyRawlings commented 10 years ago

To fix the issue. Open MetroxTextBox.cs and goto 'UpdateBaseTextBox'.

Then added the following code

baseTextBox.Cursor = base.Cursor;

After this text

baseTextBox.BackColor = EffectiveBackColor; baseTextBox.ForeColor = EffectiveForeColor; baseTextBox.Font = EffectiveFont;

recompile and it should work