Click here to Skip to main content
16,004,969 members
Home / Discussions / C#
   

C#

 
QuestionGetting the Current Open file from the Office Products Pin
s3rro19-Oct-07 8:41
s3rro19-Oct-07 8:41 
Questiondeployment problem Pin
Shuaib wasif khan19-Oct-07 7:54
Shuaib wasif khan19-Oct-07 7:54 
AnswerRe: deployment problem Pin
garyshort19-Oct-07 11:34
garyshort19-Oct-07 11:34 
AnswerRe: deployment problem Pin
il_masacratore19-Oct-07 12:55
il_masacratore19-Oct-07 12:55 
QuestionAccess Data Base problem Pin
dany_ch19-Oct-07 6:04
dany_ch19-Oct-07 6:04 
AnswerRe: Access Data Base problem Pin
Justin Perez19-Oct-07 6:44
Justin Perez19-Oct-07 6:44 
GeneralRe: Access Data Base problem Pin
dany_ch19-Oct-07 7:41
dany_ch19-Oct-07 7:41 
QuestionDrawing onto a Richtextbox (C#) Pin
c242319-Oct-07 5:08
c242319-Oct-07 5:08 
Hi,

I have been looking to find a way to draw lines onto a richtextbox control but have not been able to find anything on the web (or here). To clarify, the specific application I am working on has a requirement that the GUI looks like a piece of lined paper (i.e. I do not just want to put a bitmap into my control) which the user can type onto.

Solutions I have looked at so far include (but are not limited to):
1) Subclass richtextbox and override OnPaint to draw lines after calling base.OnPaint -> This does not work which seems to be because of the way MS implemented the base method, but I don't want to have to rewrite the entire drawing of the control if I can help it
2) Put a 50% transparent form over the top of the rtb and draw lines onto it -> I found this idea somewhere but it seems very messy, and makes it trickier to type into the rtb at the same time
3) Copy a row of - or _ characters to the clipboard and paste into the rtb -> User typing then messes up the look
4) Insert bitmap images into the rtb -> doesn't work for same reasons as 3
5) Place an rtb onto a user control or form and draw lines on the form in correct positions -> Lines get drawn underneath the control
6) Use BitBlt directly to draw on top of the control -> I haven't tried this one yet, but I would rather avoid using Interop if I can

Given that these solutions do not work (at least as far as I can tell), can anybody suggest any other approach or any references I might look at?

Thanks in advance,
Chris
AnswerRe: Drawing onto a Richtextbox (C#) Pin
Judah Gabriel Himango19-Oct-07 5:32
sponsorJudah Gabriel Himango19-Oct-07 5:32 
GeneralRe: Drawing onto a Richtextbox (C#) Pin
c242319-Oct-07 9:50
c242319-Oct-07 9:50 
GeneralRe: Drawing onto a Richtextbox (C#) Pin
Luc Pattyn19-Oct-07 10:11
sitebuilderLuc Pattyn19-Oct-07 10:11 
GeneralRe: Drawing onto a Richtextbox (C#) Pin
c242319-Oct-07 23:47
c242319-Oct-07 23:47 
GeneralRe: Drawing onto a Richtextbox (C#) Pin
Judah Gabriel Himango21-Oct-07 15:33
sponsorJudah Gabriel Himango21-Oct-07 15:33 
QuestionHandling return values from Java web service Pin
Bjohnson3319-Oct-07 4:40
Bjohnson3319-Oct-07 4:40 
AnswerRe: Handling return values from Java web service Pin
leppie19-Oct-07 4:45
leppie19-Oct-07 4:45 
GeneralRe: Handling return values from Java web service Pin
Bjohnson3319-Oct-07 5:12
Bjohnson3319-Oct-07 5:12 
GeneralRe: Handling return values from Java web service Pin
leppie19-Oct-07 6:39
leppie19-Oct-07 6:39 
AnswerRe: Handling return values from Java web service Pin
Ennis Ray Lynch, Jr.19-Oct-07 5:06
Ennis Ray Lynch, Jr.19-Oct-07 5:06 
GeneralRe: Handling return values from Java web service Pin
leppie19-Oct-07 6:39
leppie19-Oct-07 6:39 
QuestionDeployment in multi language Pin
JoZ CaVaLLo19-Oct-07 4:27
JoZ CaVaLLo19-Oct-07 4:27 
AnswerRe: Deployment in multi language Pin
Judah Gabriel Himango19-Oct-07 5:09
sponsorJudah Gabriel Himango19-Oct-07 5:09 
GeneralRe: Deployment in multi language Pin
JoZ CaVaLLo19-Oct-07 5:15
JoZ CaVaLLo19-Oct-07 5:15 
Questionideas... Pin
MasterSharp19-Oct-07 4:16
MasterSharp19-Oct-07 4:16 
AnswerRe: ideas... Pin
Guffa19-Oct-07 4:21
Guffa19-Oct-07 4:21 
GeneralRe: ideas... Pin
MasterSharp19-Oct-07 4:27
MasterSharp19-Oct-07 4:27 

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.