/ Forums / Advansys Formativ / Formativ Runtime / Formativ Applet runtime error

  • Creator
    Topic
  • #3627
    croger
    Participant

      I get this message everytime I run the Publish folder list to MS Word script:

      Formativ Applet runtime error
      Wrong number of arguments or invalid property assignment: ‘Word.ActiveDocument.Tables.Add’ at line 260, column 2

      Any ideas how I can get this to work?

    • Author
      Replies
    • #5672
      Support 2
      Moderator

        Hi,

        Which version of MS Word are you using?

        Regards,

        Advansys Support

        #5670
        croger
        Participant

          I’m using Word 97 SR2

          #5673
          Support 2
          Moderator

            MS Word 97 does not have many of the table automation commands available in later versions. For example, it appears that Word 97 does not allow us to set shading and styles that we used in the applet.

            We will email you an updated applet which now checks the Word version and, if it is Word 97, then the applet will not set the shading and color.

            Regards,

            Advansys Support

            #5674
            nsjoberg
            Participant

              When I try to publish to Word, I get this error:
              Formativ Applet compilation error
              Expected statement at line 204, column 2

              Then a dialog box that says:
              Sorry, the applet could not be executed.
              Applet could not be parsed.
              It contains errors.

              Line 204 says:
              with Selection
              in the Write Page Header function

              Is this because the applet won’t work with Word 97? Can it be altered to work?

              nancy

              #5666
              Support 2
              Moderator

                Could you please confirm which applet are you running? Was the applet installed with the product or did you download it from either our Web site or Cool Solutions?

                Once we know the exact applet, we should be able to identify and rectify the problem, which will be a Word 97 version issue.

                Regards,

                Advansys Support

                #5671
                nsjoberg
                Participant

                  I think I have tried both versions of the multiple signature file – one downloaded from Advansys and one from install. But I don’t recall any difference.

                  It also chokes on this code around line 274:
                  ‘——————————————————————————-
                  ‘ Display the available signatures in the list box
                  ‘——————————————————————————-
                  Function SetupDlg(LBCtl, FileList)

                  Set Dlg = Utilities.NewControlBoxDialog
                  With Dlg
                  .Height = 250
                  .Caption = CAPTION
                  .Title = “Select a signature”
                  .WizardImage = IMAGE
                  End With

                  It seems the Set Dlg = Utilities.NewControlBoxDialog is the objectionable line.
                  I appreciate your help –
                  Nancy

                  #5669
                  nsjoberg
                  Participant

                    When I right-click on a folder in the main window, this is the error I get. Using Word 97 SR 2. Any ideas?

                    Formativ Applet compilation error
                    Expected statement at line 204, column 2

                    applet could not be parsed….

                    Line 204 is “with selection”

                    function TypeHeader

                    dim Folder

                    Set Selection = Word.Selection

                    with Selection

                    ‘ Setup page margin
                    .PageSetup.RightMargin = 54
                    .PageSetup.LeftMargin=54

                    Thanks –
                    Nancy

                    #5667
                    Support 2
                    Moderator

                      We have uploaded a modified Publish folder list applet to our Web site for test purposes. It can be downloaded from:

                      http://www.advansyscorp.com/beta/publish folder list to ms word_bsp.vbf

                      In this modified applet, the left and right margin commands (for the word document) have been commented out (near line 274). We hope that this may work around the problem, which certainly appears to be a Word version related issue.

                      In regards to your first posting, the problem with the Multiple Signatures solution, we are unable to duplicate the problem so far. Unfortunately we have no other similar reports which may assist in identifying the cause. Does the same problem occur on multiple workstations?

                      Regards,

                      Advansys Support

                      #5668
                      nsjoberg
                      Participant

                        Thank you for the rewritten code, but I’m afraid I get another error at line 274 (the second line below):

                        set IntroDlg = Utilities.NewControlBoxDialog
                        with IntroDlg
                        .Caption = CAPTION
                        .Title = “Add or edit a message note”
                        .Button1Caption = “&Ok”
                        .Button2Caption = “&Cancel”
                        .Button3Visible = TRUE
                        .Button3Caption = “&Time Stamp”
                        .Button4Visible = TRUE
                        .Button4Caption = “&Delete Note”
                        .Description = HRT&”This applet allows you to add or edit note attached to this “&_
                        MsgType & “.” & MsgSubj & HRT & HRT &_
                        “Click ‘Time Stamp’ to add date and time inside the edit box. ” &_
                        “Click ‘Delete Note’ to delete the note attached with this message.”
                        end with

                        Does this applet require any editing on my part or will it run as is?

                        Thanks again –
                        Nancy

                        #5665
                        nsjoberg
                        Participant

                          I’m still getting the error on lines 56 and/or 273:
                          Formativ applet compilation error. Expected statement at line 56, col. 5 (or line 273, col. 2). The applet could not be parsed. It contains errors.

                          Which of these is correct syntax in lines 56-57?

                          ‘ Full path to the location of the signature files
                          SIGNATURE_LOCATION = Utilities.GetDataDirectory
                          FILENAME = SIGNATURE_LOCATION + “ADV_MultipleSignature.ol”

                          ‘ Full path to the location of the signature files
                          c:program filesadvansysformativdata = Utilities.GetDataDirectory
                          FILENAME = c:program filesadvansysformativdata + “ADV_MultipleSignature.ol”

                          Are there any other entries that I should change?

                          Nancy

                          #5675
                          Support 2
                          Moderator

                            We can’t yet determine a logical reason for the problems which you are experiencing. If you have not done so already, we recommend reinstalling Formativ.

                            It may be related to either a worksation specific configuration issue or perhaps interaction with another piece of software. Do you have any monitoring software operating, such as an anti-virus program?

                            If you are in a position to test it, does the same problem happen on another workstation?

                            Regards,

                            Advansys Support

                          Viewing 11 replies - 1 through 11 (of 11 total)
                          • You must be logged in to reply to this topic.