Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Edit box replacement in real time
#1
Hi,

In the following dialog box, I want to achieve the effect of replacing text in real time

Please look at the image below, when I enter text in the edit box on the right, the content in the edit box on the left is also replaced,  in real time

Also how to change the color of the border line of the edit box, such as the blue blue-headed arrow below

Thanks in advance for any advice and help
david


   

Macro Macro2
Code:
Copy      Help
str dd=
;BEGIN DIALOG
;0 "" 0x90C80AC8 0x0 0 0 392 192 "Dialog" "4"
;4 Edit 0x54030080 0x200 280 8 104 12 ""
;5 Edit 0x54030080 0x204 280 28 104 13 ""
;3 Edit 0x54231044 0x200 8 8 264 176 ""
;1 Button 0x54030001 0x4 280 171 48 14 "OK"
;2 Button 0x54030000 0x4 336 171 48 14 "Cancel"
;END DIALOG
;DIALOG EDITOR: "" 0x2040C02 "*" "" "" ""

str controls = "4 5 3"
str e4 e5 e3
e3=
;My name is ┆name┆, my age is ┆age┆,  thank you!

if(!ShowDialog(dd &sub.DlgProc &controls)) ret

#sub DlgProc
function# hDlg message wParam lParam

sel message
,case WM_INITDIALOG
,SendMessage id(4 hDlg) EM_SETCUEBANNER TRUE @"┆name┆"
,SendMessage id(5 hDlg) EM_SETCUEBANNER TRUE @"┆age┆"
,case WM_DESTROY
,case WM_COMMAND goto messages2
ret
;messages2
sel wParam
,case IDOK
,case IDCANCEL
ret 1


Messages In This Thread
Edit box replacement in real time - by Davider - 08-06-2022, 12:30 AM
RE: Edit box replacement in real time - by Kevin - 08-06-2022, 02:13 AM
RE: Edit box replacement in real time - by Kevin - 08-06-2022, 02:31 PM
RE: Edit box replacement in real time - by Kevin - 08-07-2022, 12:24 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)