Archive: How can i change the COLOR?


How can i change the COLOR?
  i am using UltramodernUI as skin for my installer. how can i correct the this picture(page).

Thank you!.

This is the code:

; to show the page
Page Custom serialPage serialPageLeave


i know how to call page using !insertmacro but i have no idea to create a custom one same with d picture.


this is the Function Code:


serialPage


>!insertmacro MUI_HEADER_TEXT "Enter Serial Code" "Enter the software serial code to continue."

>PassDialog::Dialog Serial
/HEADINGTEXT 'Please enter the serial code ...'
/CENTER
/BOXDASH 12 70 4 ''
/BOXDASH 92 70 4 ''
/BOXDASH 172 70 4 ''
/BOXDASH 252 70 4 ''
/BOX 332 70 4 ''

Pop $R0 # success, back, cancel or error

>FunctionEnd
>Function serialPageLeave

## Pop values from stack
Pop $R0
Pop $R1
Pop $R2
Pop $R3
Pop $R4

## A bit of validation
>StrCmp $R0 'xxxx' +4
StrCmp $R1'xxxx' +3
StrCmp $R2'xxxx' +3
StrCmp $R3'xxxx' +3
StrCmp $R4'xxxx' +3
MessageBox MB_OK
|MB_ICONEXCLAMATION "Invalid Key!"
Abort

## Display the values
>MessageBox MB_OK|MB_ICONINFORMATION "Key Accepted!"

>FunctionEnd
>

Pls Rply to my post i really really nid this next week thanks..


This is The picture pls rply for my post i really really really really need this.. NSIS PROs i need your help pls correct the color! thanks. And if its impossible, just rply your comments or suggestion thanks...

http://http://us.a2.yahoofs.com/grou...Aay4DBbO6NEji0


http://http://ph.groups.yahoo.com/gr.../view/e72d?b=3


From PassDialog's documentation:

  PassDialog::InitDialog /NOUNLOAD [dialog_name] [params]
Pop $HWNDVar
PassDialog::Show
Pop $Var

[dialog_name] : password, userpass, serial, inputbox
$HWNDVar : HWND handle of the window
$Var : success, back, cancel, error
[params] : Described under General Parameters

This method allows you to modify controls on the dialog with
SendMessage, SetCtlColors etc by using the $HWNDVar between
the InitDialog and Show calls, and also in the Page's Leave
function.
Use InitDialog and Show instead of just Dialog and then use SetCtlColors in between.

i use your code but my other page turns in to gray color.. why?? how can i insert a MUI CUSTOM PAGE and then i will put my entir script on that. thanks..


Example:

PassDialog::InitDialog /NOUNLOAD Serial            
/HEADINGTEXT 'Please enter the serial code ...'
/CENTER
/BOXDASH 12 70 4 ''
/BOXDASH 92 70 4 ''
/BOXDASH 172 70 4 ''
/BOXDASH 252 70 4 ''
/BOX 332 70 4 ''
Pop $R0 # HWND

GetDlgItem $R1 $R0 1213
SetCtlColors $R1 000000 999999

PassDialog::Show
Pop $R0 # success, back, cancel or error


This will change the colour of the heading text static label (IDC 1213). For a complete list of control ID's open up resource.h in Notepad. For the serial boxes, they start at 1200 incrementing by 1 for each serial box.

Edit: In fact I forgot to mention that the UserPass.nsi example script changes the colour of the user name and password fields.

-Stu

i test all the combination but still id didnt work. i want to change the color of the whole dialog and make it similar to the red style color of my MUI PAGE... how can i do that?, im too beginner to Solve the problem so pls help me. thanks...


awts no one can help me??? huhuhu so sad.. anyways just post your suggestion what will i do regarding the problem.. thnkxxx


This will set the background of the dialog to red. You'd probably want to set the same color for th rest of the controls. Use the method exampled in Afrow's post.

PassDialog::InitDialog /NOUNLOAD Serial \
/HEADINGTEXT 'Please enter the serial code ...' \
/CENTER \
/BOXDASH 12 70 4 '' \
/BOXDASH 92 70 4 '' \
/BOXDASH 172 70 4 '' \
/BOXDASH 252 70 4 '' \
/BOX 332 70 4 ''
Pop $R0 # HWND

SetCtlColors $R0 "" ff0000

PassDialog::Show
Pop $R0 # success, back, cancel or error

thnksz...