Posts: 58
Threads: 19
Joined: Mar 2013
Is it possible to hide the scroll bar in a rich text box, but still have the text scroll? I have tried different style settings, but do not seem to be able to get it to work. Here are the style settings I currently have
I need this because I need columns in the text box(i.e. left, centre and right align), but did not see how this was possible in one, so used three pushed up against each other - it works great, apart from it not actually scrolling when I hide the scroll bar
Kind Regards
Matt
Posts: 11,869
Threads: 138
Joined: Dec 2002
Can scroll with keyboard, but mouse wheel the does not work, don't know is it possible.
Posts: 58
Threads: 19
Joined: Mar 2013
Thanks for your reply Gintaras.
If it is not possible to hide the scroll bar, is it possible to align text differently within the same rich text box? So some text would be left aligned, some would be center and some right - all within the one text box.
Regards
Matt
Posts: 11,869
Threads: 138
Joined: Dec 2002
Don't know. QM uses standard rich text controls. You can google for rich text control columns RTF...
Posts: 58
Threads: 19
Joined: Mar 2013
Thanks Gintaras, I will take a look.
Kind Regards
Matt
Posts: 58
Threads: 19
Joined: Mar 2013
Oh one other question, is it possible to clear the contents of the rich text box while the macro is running and start scrolling new text again from the top? I tried doing it with a loop but was not sure how to get the cursor back the the start of the RTB, before clearing the contents.
This simply entered blank text after the 11th line (height of the RTB control) but I wanted it to clear it from the top.
Macro marquee2
function hDlg
;SendMessage hDlg WM_APP 4 F"{num}"
;SendMessage hDlg WM_APP 5 ""
;SendMessage hDlg WM_APP 3 ""
int inc
int inc1
int number
int clearMarq=1
for inc 0 100
,number=RandomInt(0 2)
,sel number
,,case 0
,,SendMessage hDlg WM_APP 4 F"{number}"
,,SendMessage hDlg WM_APP 5 ""
,,SendMessage hDlg WM_APP 3 ""
,,case 1
,,SendMessage hDlg WM_APP 3 F"{number}"
,,SendMessage hDlg WM_APP 5 ""
,,SendMessage hDlg WM_APP 4 ""
,,case 2
,,SendMessage hDlg WM_APP 5 F"{number}"
,,SendMessage hDlg WM_APP 4 ""
,,SendMessage hDlg WM_APP 3 ""
,wait 1
,clearMarq=clearMarq+1
,if clearMarq=11
,,for inc1 0 11
,,,SendMessage hDlg WM_APP 4 ""
,,,SendMessage hDlg WM_APP 5 ""
,,,SendMessage hDlg WM_APP 3 ""
,,,clearMarq=1
Kind Regards
Matt
Posts: 11,869
Threads: 138
Joined: Dec 2002
setwintext or EditReplaceSel or edit/richedit control messages
Posts: 58
Threads: 19
Joined: Mar 2013
Gintaras Wrote:setwintext or EditReplaceSel or edit/richedit control messages
setwintext works perfectly, thankyou!
|