flat assembler
Message board for the users of flat assembler.

Index > Windows > EDITbox - CRLF ?

Author
Thread Post new topic Reply to topic
ouadji



Joined: 24 Dec 2008
Posts: 1081
Location: Belgium
ouadji

How to display carriage return in an editbox?
(to display multiple lines)
thank you.

_________________
I am not young enough to know everything (Oscar Wilde)- Image
Post 30 Jan 2011, 01:55
View user's profile Send private message Send e-mail Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 17664
Location: In your JS exploiting you and your system
revolution
TFM wrote:
ES_MULTILINE
Designates a multiline edit control. The default is single-line edit control.
When the multiline edit control is in a dialog box, the default response to pressing the ENTER key is to activate the default button. To use the ENTER key as a carriage return, use the ES_WANTRETURN style.
Is that what you mean?

Or do you want to display ¶ or ↲ at the end of each line?


Last edited by revolution on 30 Jan 2011, 02:52; edited 1 time in total
Post 30 Jan 2011, 02:00
View user's profile Send private message Visit poster's website Reply with quote
edfed



Joined: 20 Feb 2006
Posts: 4242
Location: 2018
edfed
he means showing the code as ascii view in hexadecimal editor i think.

"CRLF" string can be cool!!! to separate lines on only one line.

org 100h CRLF mov ax,13h CRLF int 10h CRLF

or find what char you want. it is a totally free choice!!!

org 100h Smile mov ax,13h Smile int 10h Smile
Post 30 Jan 2011, 02:20
View user's profile Send private message Visit poster's website Reply with quote
ouadji



Joined: 24 Dec 2008
Posts: 1081
Location: Belgium
ouadji

"ES_MULTILINE "
i know that, but it doesn't solve my problem.

Or do you want to display ¶ or ↲ at the end of each line? <--- yes !

Code:
string_a db 'a',0
string_b db 'b',0
invoke        SendMessage,[hwnd],WM_SETTEXT,0,string_a
invoke      SendMessage,[hwnd],WM_SETTEXT,0,string_b
;..... (10 lines)

;result 
;a
;b
;...
    

or do I need to use something other than an edit box?

@edfed: int 10h ? with Windows WP ? Wink

_________________
I am not young enough to know everything (Oscar Wilde)- Image
Post 30 Jan 2011, 08:18
View user's profile Send private message Send e-mail Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 17664
Location: In your JS exploiting you and your system
revolution
Subclass the edit box.
Post 30 Jan 2011, 09:27
View user's profile Send private message Visit poster's website Reply with quote
ouadji



Joined: 24 Dec 2008
Posts: 1081
Location: Belgium
ouadji

thank you for your reply revolution,
Quote:

Subclass the edit box ...
i don't know how to create a subclassed editbox Confused

can you help me ? (thank you)


_________________
I am not young enough to know everything (Oscar Wilde)- Image
Post 30 Jan 2011, 09:39
View user's profile Send private message Send e-mail Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 17664
Location: In your JS exploiting you and your system
revolution
Code:
  invoke SetWindowLong,[edithwnd],GWL_WNDPROC,MyDrawProc
;...
proc MyDrawProc,...
  cmp [msg],wm_paint
  je .do_my_custom_draw
  invoke CallWindowProc,...
;...    
Post 30 Jan 2011, 10:08
View user's profile Send private message Visit poster's website Reply with quote
ouadji



Joined: 24 Dec 2008
Posts: 1081
Location: Belgium
ouadji

ok, thank you, understood.
but ... is there another way to simply display multiple lines of text in a window ?

_________________
I am not young enough to know everything (Oscar Wilde)- Image
Post 30 Jan 2011, 10:34
View user's profile Send private message Send e-mail Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar. Also on GitHub, YouTube, Twitter.

Website powered by rwasa.