Execute Dataview Macro??

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Execute Dataview Macro??

    Does anyone know how i can execute a dataview macro from within a part routine? I want to spit out an updated xbarr each time a part is ran.

    I have used the fptr/read/write stuff before but i am pretty sure it will only open the file as text NOT execute..........

    Any suggestions would be helpful!!!!

  • #2
    If Dataveiw is exposed to automation AND there is a method for executing macros through automation then it might be possible. I do not know enough about it to be able to recomend another way.

    We have plenty of Datapage/Dataview users here so maybe there is an easy way.

    What do the help files say about automation?
    <internet bumper sticker goes here>

    Comment


    • #3
      As far as the help files....I looked up automation and lets just say this is an area where i dont have a clue what the **** there explaining. Just not at that level yet!

      Comment


      • #4
        BAT file

        Originally posted by spazus_maximus View Post
        Does anyone know how i can execute a dataview macro from within a part routine? I want to spit out an updated xbarr each time a part is ran.

        I have used the fptr/read/write stuff before but i am pretty sure it will only open the file as text NOT execute..........

        Any suggestions would be helpful!!!!
        It's been a long time since I usewd DataView. I belive the macros are not that much different than DataPage.

        If you can create a macro which opens DataView and creates the report you want, then all you would nneed to do is to store that command line syntax into text file, and use the extension '.bat' instead of '.txt. This will allow PC-DMIS to access it as an external command.

        Comment


        • #5
          Create the macro within DV, save it.
          You should be able to call the DV executable and pass it the macro name as an argument within PCDMIS with the EXTERNAL command. I can't remember if DV has a print option for the macro or not.

          Comment


          • #6
            Originally posted by SABarber View Post
            Create the macro within DV, save it.
            You should be able to call the DV executable and pass it the macro name as an argument within PCDMIS with the EXTERNAL command. I can't remember if DV has a print option for the macro or not.
            For clarification I will be using datapage macros instead of dataview(simpler)

            I can use the external command to open datapage just fine.
            But i can not seem to execute the macro. When you say pass the macro could you show me what that would look like?

            Thanks

            Comment


            • #7
              Using V37MR3 I can put in:
              EXTERNALCOMMAND/NO_DISPLAY, NO_WAIT ; E:\DATAPAGE33\DATAPAGE.EXE E:\DATAPAGE33\Run.MAC
              Which will execute DP using the RUN.MAC file.

              Run.MAC contains the following:
              Part DEMO;
              Variable CIR0.X,
              CIR0.Y,
              CIR1.D;
              Last 30;
              RunChartLabel ;
              RunChartAnnotate 1;
              RunChart;

              Which will generate a run chart for the last 30 transactions using part DEMO and CIR0.X, CIR0.Y, CIR0.D variables.
              I could have added a PRINT; command to print the charts.
              I am not sure if this will work with all versions of PCDMIS.

              Another way is to create a BAT file (ie. DPRUN.BAT) and put the
              E:\DATAPAGE33\DATAPAGE.EXE E:\DATAPAGE33\Run.MAC
              in that file and have PCDMIS execute the BAT file instead. I think this is what Don (above) indicated.

              Comment


              • #8
                I got it!

                Thanks SAbarber & everyone for your input.

                Comment

                Related Topics

                Collapse

                Working...
                X