Compare 2 parameters in action script

(imported topic written by gbabbitt91)

Is it possible to compare 2 parameters in an action script?

I would like to be able to compare parameter1 to parameter2 and if they are not the same then run command.

This is what I had in mind…

parameter “usr” = “{name of current user as string}”

parameter “lastusr” = “{values “LastUser” of key “HKLM\System\Build” of registry as string}”

if {parameter “usr”} != {parameter “lastusr”}

regset "

HKEY_LOCAL_MACHINE\System\Build

" “LastUser”="{parameter “usr”}"

endif

thanks

Greg

(imported comment written by SystemAdmin)

Hi Greg,

I think you want to put everything inside 1 single set of braces…

if {parameter “usr” != parameter “lastusr”}

-Paul

(imported comment written by gbabbitt91)

Thanks Paul. That worked.