Prev Previous Post   Next Post Next
Old 3rd October 2011, 15:58   #1
Junior Member
Join Date: Apr 2011
Posts: 15
Endless Marquee in nsWindows popup

Hi everyone,

Am using the nsWindows plugin to create popups, and almost have the marquee working. My intention was to generate the marquee whenever some work is being done (function being called, etc), just so the user had some some that something was moving.

I managed to get the popup to show just fine, but the marquee itself is not - it's just blank.

This is the main page:
Function OnClickLookup
EnableWindow $HWNDPARENT 1
${NSW_CreateWindow} $WINDOW "Look up your key" 1044
;set window size
${NSW_SetWindowSize} $WINDOW 400 200
${NSW_CenterWindow} $WINDOW $hwndparent

${NSW_CreateLabel} 40 90 80 20 "Email Address:"
Pop $0

${NSW_CreateText} 140 90 200 20 $email
Pop $emailTextBox

${NSW_CreateButton} 100 130 85 30 "&Find my key"
${NSW_OnClick} $GETKEY onClickGetKey


This is the leave code (onClickGetKey):
Function onClickGetKey
${NSW_GetText} $fullNameTextBox $fullName
${NSW_GetText} $emailTextBox $email

; We require a valid email address to verify the activation, for all users
push "^[a-zA-Z][\w\.-]*[a-zA-Z0-9]@[a-zA-Z0-9][\w\.-]*[a-zA-Z0-9]\.[a-zA-Z][a-zA-Z\.]*[a-zA-Z]$"
push $email
pop $R1 ;true/false
${IF} $R1 == "false"
${ORIF} $R1 == ""
Messagebox MB_OK|MB_ICONEXCLAMATION "Your email is invalid." IDOK errors

call Timer

push $email
push $productcode
pop $0
Push " " ;divider char
Push $0 ;input string
Call SplitFirstStrPart
Pop $R0 ;1st part ["string1"]

${IF} $R0 == "ERROR"
${ORIF} $R0 == "RPC"
call destroyTimerWindow
call destroyTimerWindow
MessageBox MB_OK|MB_SETFOREGROUND "Your License Key has been sent to your email."

StrCpy $R9 "0"
Call RelGotoPage

And this is my timer code:

Function Timer
${NSW_CreateWindow} $TIMER "Submitting" 1044
${NSW_SetWindowSize} $TIMER 250 50
${NSW_CenterWindow} $TIMER $WINDOW

${NSW_CreateProgressBar} 0 0 100% 100% "Submitting"
Pop $hwnd
${NSW_AddStyle} $hwnd ${PBS_MARQUEE}

${NSW_CreateTimer} NSW_Timer.Callback 10

Function NSW_Timer.Callback
${NSW_KillTimer} NSW_Timer.Callback ; Kill the timer
SendMessage $hwnd ${PBM_SETMARQUEE} 1 50 ; start=1|stop=0 interval(ms)=+N

Function destroyTimerWindow
${NSW_DestroyWindow} $TIMER

I've also attached a screencap of what am seeing. Am thinking I have the wrong Window?
Attached Thumbnails
Click image for larger version

Name:	popup.jpg
Views:	186
Size:	26.8 KB
ID:	49192  
hphantom is offline   Reply With Quote
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump