Any suggestions on how to simplify this list of actions?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts
  • TJ_Tigger
    Indigo Rose Customer
    • Sep 2002
    • 3159

    Any suggestions on how to simplify this list of actions?

    I hope you don't mind me posting these actions here. I am trying to accomplish a couple of things. The first is getting it to work. I appears to work, I need to uninstall acrobat and test it with out a supported browser and with an older version. The second thing is I am looking for ways to either simplify the actions list or make it better.

    Your help is greatly appreciated.

    <IR_ACTIONS_LIST>
    <Action name="Comment">
    <Type>202</Type>
    <Function>2</Function>
    <DTIndentLevel>0</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    <Comment>Set a default value for our test</Comment>
    </Action>
    <Action name="Set Value">
    <Type>6</Type>
    <Function>0</Function>
    <DTIndentLevel>0</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    <Variable>%pdfviewer%</Variable>
    <Value>NOTFOUND</Value>
    <Evaluate>0</Evaluate>
    </Action>
    <Action name="Comment">
    <Type>202</Type>
    <Function>2</Function>
    <DTIndentLevel>0</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    <Comment>Note: I've set the On Error user notification to "none" for the next action</Comment>
    </Action>
    <Action name="Get Default Viewer">
    <Type>13</Type>
    <Function>0</Function>
    <DTIndentLevel>0</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>0</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    <Variable>%pdfviewer%</Variable>
    <FileExtension>.PDF</FileExtension>
    </Action>
    <Action name="IF">
    <Type>200</Type>
    <Function>1</Function>
    <DTIndentLevel>0</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    <Condition>%pdfviewer% = "NOTFOUND"</Condition>
    </Action>
    <Action name="Message Box">
    <Type>5</Type>
    <Function>0</Function>
    <DTIndentLevel>1</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    <DialogTitle>Acrobat Reader Not Found</DialogTitle>
    <DialogMessage>Acrobat Reader doesn't appear to be installed on your PC. To read this file, Acrobat Reader will need to be installed.</DialogMessage>
    <Icon>3</Icon>
    <Variable>%acroResult%</Variable>
    <DialogType>2</DialogType>
    <DefaultButton>0</DefaultButton>
    </Action>
    <Action name="IF">
    <Type>200</Type>
    <Function>1</Function>
    <DTIndentLevel>1</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    <Condition>%acroResult% = "OK"</Condition>
    </Action>
    <Action name="Execute">
    <Type>8</Type>
    <Function>0</Function>
    <DTIndentLevel>2</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    <FileName>%SrcDir%\AcrobatReader\ar505enu.exe</FileName>
    <CommandLine/>
    <WorkingDir/>
    <RunMode>0</RunMode>
    <WaitForReturn>1</WaitForReturn>
    </Action>
    <Action name="END IF">
    <Type>201</Type>
    <Function>1</Function>
    <DTIndentLevel>1</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    </Action>
    <Action name="ELSE">
    <Type>206</Type>
    <Function>1</Function>
    <DTIndentLevel>0</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    </Action>
    <Action name="Get Information">
    <Type>14</Type>
    <Function>0</Function>
    <DTIndentLevel>1</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>0</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    <FileInformationToCollect>0</FileInformationToCollect>
    <Variable>%pdfversion%</Variable>
    <FileName>%pdfviewer%</FileName>
    </Action>
    <Action name="IF">
    <Type>200</Type>
    <Function>1</Function>
    <DTIndentLevel>1</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    <Condition>%pdfversion% &amp;lt; 5</Condition>
    </Action>
    <Action name="Message Box">
    <Type>5</Type>
    <Function>0</Function>
    <DTIndentLevel>2</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    <DialogTitle>Update Acrobat Reader</DialogTitle>
    <DialogMessage>A newer version of Acrobat Reader is available would you like to install a newer version?</DialogMessage>
    <Icon>3</Icon>
    <Variable>%acroversion%</Variable>
    <DialogType>1</DialogType>
    <DefaultButton>1</DefaultButton>
    </Action>
    <Action name="IF">
    <Type>200</Type>
    <Function>1</Function>
    <DTIndentLevel>2</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    <Condition>%acroversion% = "YES"</Condition>
    </Action>
    <Action name="Execute">
    <Type>8</Type>
    <Function>0</Function>
    <DTIndentLevel>3</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    <FileName>%SrcDir%\AcrobatReader\ar505enu.exe</FileName>
    <CommandLine/>
    <WorkingDir/>
    <RunMode>0</RunMode>
    <WaitForReturn>1</WaitForReturn>
    </Action>
    <Action name="END IF">
    <Type>201</Type>
    <Function>1</Function>
    <DTIndentLevel>2</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    </Action>
    <Action name="ELSE">
    <Type>206</Type>
    <Function>1</Function>
    <DTIndentLevel>1</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    </Action>
    <Action name="Open">
    <Type>7</Type>
    <Function>0</Function>
    <DTIndentLevel>2</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    <FileName>%SrcDir%\pdf\main.pdf</FileName>
    <Verb>open</Verb>
    <WorkingDir/>
    <RunMode>0</RunMode>
    </Action>
    <Action name="END IF">
    <Type>201</Type>
    <Function>1</Function>
    <DTIndentLevel>1</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    </Action>
    <Action name="END IF">
    <Type>201</Type>
    <Function>1</Function>
    <DTIndentLevel>0</DTIndentLevel>
    <Enabled>1</Enabled>
    <ErrorHandling>
    <UserNotificationMode>2</UserNotificationMode>
    <CustomErrorMessage/>
    <OnErrorAction>0</OnErrorAction>
    <JumpToLabel/>
    </ErrorHandling>
    </Action>
    </IR_ACTIONS_LIST>
    TJ-Tigger
    "A common mistake that people make when trying to design something completely foolproof was to underestimate the ingenuity of complete fools."
    "Draco dormiens nunquam titillandus."
    Map of IR Forum Users - IR Project CodeViewer - Online Help - TiggTV - QuizEngine
  • Corey
    Indigo Rose Staff Alumni
    • Aug 2002
    • 9745

    #2
    Re: Any suggestions on how to simplify this list of actions?

    I'm not the master of elegance in coding yet, but just a note, it's fine to post your actions here, etc. No probs. As a matter of fact it's kind of cool to see people who are willing to put in a little extra effort to try and make things as slick as possible. [img]/ubbthreads/images/icons/smile.gif[/img]

    Corey Milner
    Creative Director, Indigo Rose Software

    Comment

    • Protocol
      Indigo Rose Customer
      • Oct 2002
      • 423

      #3
      Re: Any suggestions on how to simplify this list of actions?

      I agree. Tigg's got some great scripts. I try to read his as much as possible. Keep up the great work!


      Protocol
      "White-colla-AMS-gangsta."

      Comment

      Working...
      X