Click here to Skip to main content
15,886,519 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: format date Pin
jds120723-Feb-07 9:19
jds120723-Feb-07 9:19 
GeneralRe: format date Pin
Marcus J. Smith23-Feb-07 9:26
professionalMarcus J. Smith23-Feb-07 9:26 
GeneralRe: format date Pin
jds120723-Feb-07 9:53
jds120723-Feb-07 9:53 
GeneralRe: format date Pin
Marcus J. Smith23-Feb-07 10:04
professionalMarcus J. Smith23-Feb-07 10:04 
GeneralRe: format date Pin
Dave Kreskowiak23-Feb-07 10:27
mveDave Kreskowiak23-Feb-07 10:27 
QuestionCaret Size Pin
Anybloodyid23-Feb-07 7:54
Anybloodyid23-Feb-07 7:54 
AnswerRe: Caret Size Pin
Dave Kreskowiak23-Feb-07 10:25
mveDave Kreskowiak23-Feb-07 10:25 
AnswerRe: Caret Size [modified] Pin
TwoFaced23-Feb-07 11:32
TwoFaced23-Feb-07 11:32 
Does the caret actually change or is it just the spacing that changes. I tried it by setting a large font as the default font. I ran the program and typed some stuff and then clicked a button which altered the selectionfont to a smaller font. When I hit enter the caret was the appropriate height but the space for the line appeared to fit the larger default font. Once I typed something the spacing was set correctly but the issue persisted with every new line I made.

I messed around with overriding wndproc and I think I guessed correctly. I seem to have fixed the issue. You'll have to create your own class that inherits the richtextbox. The fix is a simple one. However, you'll have to use your 'new' control instead of the standard richtextbox. Here is the code. Let me know if you have any issues.
Public Class MyRTB
    Inherits RichTextBox
    Protected Overrides Sub WndProc(ByRef m As System.Windows.Forms.Message)
        If m.Msg = &H444 AndAlso m.WParam.ToInt32 = 1 Then m.WParam = New System.IntPtr(3)

        MyBase.WndProc(m)
    End Sub
End Class



-- modified at 18:10 Friday 23rd February, 2007
GeneralRe: Caret Size Pin
Dave Kreskowiak23-Feb-07 14:02
mveDave Kreskowiak23-Feb-07 14:02 
GeneralRe: Caret Size Pin
TwoFaced23-Feb-07 14:31
TwoFaced23-Feb-07 14:31 
GeneralRe: Caret Size Pin
Anybloodyid23-Feb-07 22:53
Anybloodyid23-Feb-07 22:53 
GeneralRe: Caret Size Pin
TwoFaced23-Feb-07 23:51
TwoFaced23-Feb-07 23:51 
GeneralRe: Caret Size Pin
Anybloodyid24-Feb-07 1:22
Anybloodyid24-Feb-07 1:22 
GeneralRe: Caret Size Pin
TwoFaced24-Feb-07 8:28
TwoFaced24-Feb-07 8:28 
GeneralRe: Caret Size Pin
Anybloodyid24-Feb-07 9:42
Anybloodyid24-Feb-07 9:42 
GeneralRe: Caret Size Pin
TwoFaced24-Feb-07 10:14
TwoFaced24-Feb-07 10:14 
GeneralRe: Caret Size Pin
Anybloodyid24-Feb-07 11:11
Anybloodyid24-Feb-07 11:11 
GeneralRe: Caret Size Pin
TwoFaced24-Feb-07 12:54
TwoFaced24-Feb-07 12:54 
GeneralRe: Caret Size Pin
Anybloodyid24-Feb-07 22:47
Anybloodyid24-Feb-07 22:47 
GeneralRe: Caret Size Pin
TwoFaced24-Feb-07 23:17
TwoFaced24-Feb-07 23:17 
GeneralRe: Caret Size Pin
Anybloodyid25-Feb-07 0:50
Anybloodyid25-Feb-07 0:50 
Questionincluiding calculator in my vb.net application Pin
manni_n23-Feb-07 7:04
manni_n23-Feb-07 7:04 
AnswerRe: incluiding calculator in my vb.net application Pin
Dave Kreskowiak23-Feb-07 7:33
mveDave Kreskowiak23-Feb-07 7:33 
GeneralRe: incluiding calculator in my vb.net application [modified] Pin
manni_n23-Feb-07 8:10
manni_n23-Feb-07 8:10 
GeneralRe: incluiding calculator in my vb.net application Pin
Dave Kreskowiak23-Feb-07 8:29
mveDave Kreskowiak23-Feb-07 8:29 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.