Yeah I haven't figured out how to copy code from this or any other source and put it directly into voice attack ...
You cannot copy "code" or examples of VoiceAttack actions such as those presented by Pfeil above. This is not in fact code, but a list of actions as they would appear in a VoiceAttack command once they are manually added by us users.
These actions have individual options menu screens, and so could not be copy/pasted even if it was possible because a lot of information would be lost - for example, the checkbox to evaluate 'not set' as 'current date/time' for setting a date/time variable, among others.
When we share these examples, it's required to add each individual action as you had done, so that once complete, the actions list looks exactly like the example provided. The only way to actually share a command that would function would be to share a VoiceAttack profile containing the command(s) already configured, but it more preferable for us to teach users how to create these things for themselves and work through the actions necessary rather than simply provide a working command by sharing an example profile with example command(s). This way, we are preparing you to create anything you can dream up in VoiceAttack commands as opposed to teaching you to ask someone to make the things for you upon request.
Glad you got it working!! Congrats and best wishes with your profile commands!