+ Reply to Thread
Results 1 to 7 of 7

Regression

  1. #1
    Ubirajara Augusto
    Guest

    Regression

    I am trying to automate running of regression macros in Excel. I used the
    "record" method to create one. But everytime I run the "recorded" regression
    macro, I get the error message:

    "Macro 'ATPVBAEN.XLA!Regression' could not be found.

    Code:

    Application.Run "ATPVBAEN.XLA!Regression", ActiveSheet.Range("$B$2:$B$50"), _
    ActiveSheet.Range("$A$2:$A$50"), True, True, 95, "AUX44", True,
    True, True _
    , True, , True

    What can I do?

    Thanks.

  2. #2
    Nigel
    Guest

    Re: Regression

    ATPVBAEN.XLA is an add-in, you need to ensure that this is installed before
    you run the macro, alternatively change the macro to include this add-in
    before the regression command eg

    AddIns("Name of Addin").Installed = True

    your code to run the analysis using the addin functions

    AddIns("Name of Addin").Installed = False

    --
    Cheers
    Nigel



    "Ubirajara Augusto" <Ubirajara [email protected]> wrote in
    message news:[email protected]...
    > I am trying to automate running of regression macros in Excel. I used the
    > "record" method to create one. But everytime I run the "recorded"

    regression
    > macro, I get the error message:
    >
    > "Macro 'ATPVBAEN.XLA!Regression' could not be found.
    >
    > Code:
    >
    > Application.Run "ATPVBAEN.XLA!Regression",

    ActiveSheet.Range("$B$2:$B$50"), _
    > ActiveSheet.Range("$A$2:$A$50"), True, True, 95, "AUX44", True,
    > True, True _
    > , True, , True
    >
    > What can I do?
    >
    > Thanks.




  3. #3
    Ubirajara Augusto
    Guest

    Re: Regression

    Thanks but the same message continues to appear.
    Do you have any other tip?

    "Nigel" escreveu:

    > ATPVBAEN.XLA is an add-in, you need to ensure that this is installed before
    > you run the macro, alternatively change the macro to include this add-in
    > before the regression command eg
    >
    > AddIns("Name of Addin").Installed = True
    >
    > your code to run the analysis using the addin functions
    >
    > AddIns("Name of Addin").Installed = False
    >
    > --
    > Cheers
    > Nigel
    >
    >
    >
    > "Ubirajara Augusto" <Ubirajara [email protected]> wrote in
    > message news:[email protected]...
    > > I am trying to automate running of regression macros in Excel. I used the
    > > "record" method to create one. But everytime I run the "recorded"

    > regression
    > > macro, I get the error message:
    > >
    > > "Macro 'ATPVBAEN.XLA!Regression' could not be found.
    > >
    > > Code:
    > >
    > > Application.Run "ATPVBAEN.XLA!Regression",

    > ActiveSheet.Range("$B$2:$B$50"), _
    > > ActiveSheet.Range("$A$2:$A$50"), True, True, 95, "AUX44", True,
    > > True, True _
    > > , True, , True
    > >
    > > What can I do?
    > >
    > > Thanks.

    >
    >
    >


  4. #4
    Nigel
    Guest

    Re: Regression

    Use the following addin reference

    AddIns("Analysis ToolPak - VBA").Installed = True

    your code

    AddIns("Analysis ToolPak - VBA").Installed = False


    --
    Cheers
    Nigel



    "Ubirajara Augusto" <[email protected]> wrote in
    message news:[email protected]...
    > Thanks but the same message continues to appear.
    > Do you have any other tip?
    >
    > "Nigel" escreveu:
    >
    > > ATPVBAEN.XLA is an add-in, you need to ensure that this is installed

    before
    > > you run the macro, alternatively change the macro to include this add-in
    > > before the regression command eg
    > >
    > > AddIns("Name of Addin").Installed = True
    > >
    > > your code to run the analysis using the addin functions
    > >
    > > AddIns("Name of Addin").Installed = False
    > >
    > > --
    > > Cheers
    > > Nigel
    > >
    > >
    > >
    > > "Ubirajara Augusto" <Ubirajara [email protected]> wrote

    in
    > > message news:[email protected]...
    > > > I am trying to automate running of regression macros in Excel. I used

    the
    > > > "record" method to create one. But everytime I run the "recorded"

    > > regression
    > > > macro, I get the error message:
    > > >
    > > > "Macro 'ATPVBAEN.XLA!Regression' could not be found.
    > > >
    > > > Code:
    > > >
    > > > Application.Run "ATPVBAEN.XLA!Regression",

    > > ActiveSheet.Range("$B$2:$B$50"), _
    > > > ActiveSheet.Range("$A$2:$A$50"), True, True, 95, "AUX44",

    True,
    > > > True, True _
    > > > , True, , True
    > > >
    > > > What can I do?
    > > >
    > > > Thanks.

    > >
    > >
    > >




  5. #5
    Ubirajara Augusto
    Guest

    Re: Regression

    That's exactly what I did, but it didn't work.
    Do you know if I have to activate any other option in VBA?
    Have you ever used the regression library (inside Analysis Toolpack) in VBA?
    If you've ever used, could you send me the code / file?

    Thank's again.


    "Nigel" escreveu:

    > Use the following addin reference
    >
    > AddIns("Analysis ToolPak - VBA").Installed = True
    >
    > your code
    >
    > AddIns("Analysis ToolPak - VBA").Installed = False
    >
    >
    > --
    > Cheers
    > Nigel
    >
    >
    >
    > "Ubirajara Augusto" <[email protected]> wrote in
    > message news:[email protected]...
    > > Thanks but the same message continues to appear.
    > > Do you have any other tip?
    > >
    > > "Nigel" escreveu:
    > >
    > > > ATPVBAEN.XLA is an add-in, you need to ensure that this is installed

    > before
    > > > you run the macro, alternatively change the macro to include this add-in
    > > > before the regression command eg
    > > >
    > > > AddIns("Name of Addin").Installed = True
    > > >
    > > > your code to run the analysis using the addin functions
    > > >
    > > > AddIns("Name of Addin").Installed = False
    > > >
    > > > --
    > > > Cheers
    > > > Nigel
    > > >
    > > >
    > > >
    > > > "Ubirajara Augusto" <Ubirajara [email protected]> wrote

    > in
    > > > message news:[email protected]...
    > > > > I am trying to automate running of regression macros in Excel. I used

    > the
    > > > > "record" method to create one. But everytime I run the "recorded"
    > > > regression
    > > > > macro, I get the error message:
    > > > >
    > > > > "Macro 'ATPVBAEN.XLA!Regression' could not be found.
    > > > >
    > > > > Code:
    > > > >
    > > > > Application.Run "ATPVBAEN.XLA!Regression",
    > > > ActiveSheet.Range("$B$2:$B$50"), _
    > > > > ActiveSheet.Range("$A$2:$A$50"), True, True, 95, "AUX44",

    > True,
    > > > > True, True _
    > > > > , True, , True
    > > > >
    > > > > What can I do?
    > > > >
    > > > > Thanks.
    > > >
    > > >
    > > >

    >
    >
    >


  6. #6
    Nigel
    Guest

    Re: Regression

    Try changing the command

    ATPVBAEN.XLA!Regression

    to

    ATPVBAEN.XLA!Regress

    --
    Cheers
    Nigel



    "Ubirajara Augusto" <[email protected]> wrote in
    message news:[email protected]...
    > That's exactly what I did, but it didn't work.
    > Do you know if I have to activate any other option in VBA?
    > Have you ever used the regression library (inside Analysis Toolpack) in

    VBA?
    > If you've ever used, could you send me the code / file?
    >
    > Thank's again.
    >
    >
    > "Nigel" escreveu:
    >
    > > Use the following addin reference
    > >
    > > AddIns("Analysis ToolPak - VBA").Installed = True
    > >
    > > your code
    > >
    > > AddIns("Analysis ToolPak - VBA").Installed = False
    > >
    > >
    > > --
    > > Cheers
    > > Nigel
    > >
    > >
    > >
    > > "Ubirajara Augusto" <[email protected]> wrote

    in
    > > message news:[email protected]...
    > > > Thanks but the same message continues to appear.
    > > > Do you have any other tip?
    > > >
    > > > "Nigel" escreveu:
    > > >
    > > > > ATPVBAEN.XLA is an add-in, you need to ensure that this is

    installed
    > > before
    > > > > you run the macro, alternatively change the macro to include this

    add-in
    > > > > before the regression command eg
    > > > >
    > > > > AddIns("Name of Addin").Installed = True
    > > > >
    > > > > your code to run the analysis using the addin functions
    > > > >
    > > > > AddIns("Name of Addin").Installed = False
    > > > >
    > > > > --
    > > > > Cheers
    > > > > Nigel
    > > > >
    > > > >
    > > > >
    > > > > "Ubirajara Augusto" <Ubirajara [email protected]>

    wrote
    > > in
    > > > > message news:[email protected]...
    > > > > > I am trying to automate running of regression macros in Excel. I

    used
    > > the
    > > > > > "record" method to create one. But everytime I run the "recorded"
    > > > > regression
    > > > > > macro, I get the error message:
    > > > > >
    > > > > > "Macro 'ATPVBAEN.XLA!Regression' could not be found.
    > > > > >
    > > > > > Code:
    > > > > >
    > > > > > Application.Run "ATPVBAEN.XLA!Regression",
    > > > > ActiveSheet.Range("$B$2:$B$50"), _
    > > > > > ActiveSheet.Range("$A$2:$A$50"), True, True, 95, "AUX44",

    > > True,
    > > > > > True, True _
    > > > > > , True, , True
    > > > > >
    > > > > > What can I do?
    > > > > >
    > > > > > Thanks.
    > > > >
    > > > >
    > > > >

    > >
    > >
    > >




  7. #7
    Ubirajara Augusto
    Guest

    Re: Regression

    It's working...
    Thank's - it will help me a lot of some work stuff...

    "Nigel" escreveu:

    > Try changing the command
    >
    > ATPVBAEN.XLA!Regression
    >
    > to
    >
    > ATPVBAEN.XLA!Regress
    >
    > --
    > Cheers
    > Nigel
    >
    >
    >
    > "Ubirajara Augusto" <[email protected]> wrote in
    > message news:[email protected]...
    > > That's exactly what I did, but it didn't work.
    > > Do you know if I have to activate any other option in VBA?
    > > Have you ever used the regression library (inside Analysis Toolpack) in

    > VBA?
    > > If you've ever used, could you send me the code / file?
    > >
    > > Thank's again.
    > >
    > >
    > > "Nigel" escreveu:
    > >
    > > > Use the following addin reference
    > > >
    > > > AddIns("Analysis ToolPak - VBA").Installed = True
    > > >
    > > > your code
    > > >
    > > > AddIns("Analysis ToolPak - VBA").Installed = False
    > > >
    > > >
    > > > --
    > > > Cheers
    > > > Nigel
    > > >
    > > >
    > > >
    > > > "Ubirajara Augusto" <[email protected]> wrote

    > in
    > > > message news:[email protected]...
    > > > > Thanks but the same message continues to appear.
    > > > > Do you have any other tip?
    > > > >
    > > > > "Nigel" escreveu:
    > > > >
    > > > > > ATPVBAEN.XLA is an add-in, you need to ensure that this is

    > installed
    > > > before
    > > > > > you run the macro, alternatively change the macro to include this

    > add-in
    > > > > > before the regression command eg
    > > > > >
    > > > > > AddIns("Name of Addin").Installed = True
    > > > > >
    > > > > > your code to run the analysis using the addin functions
    > > > > >
    > > > > > AddIns("Name of Addin").Installed = False
    > > > > >
    > > > > > --
    > > > > > Cheers
    > > > > > Nigel
    > > > > >
    > > > > >
    > > > > >
    > > > > > "Ubirajara Augusto" <Ubirajara [email protected]>

    > wrote
    > > > in
    > > > > > message news:[email protected]...
    > > > > > > I am trying to automate running of regression macros in Excel. I

    > used
    > > > the
    > > > > > > "record" method to create one. But everytime I run the "recorded"
    > > > > > regression
    > > > > > > macro, I get the error message:
    > > > > > >
    > > > > > > "Macro 'ATPVBAEN.XLA!Regression' could not be found.
    > > > > > >
    > > > > > > Code:
    > > > > > >
    > > > > > > Application.Run "ATPVBAEN.XLA!Regression",
    > > > > > ActiveSheet.Range("$B$2:$B$50"), _
    > > > > > > ActiveSheet.Range("$A$2:$A$50"), True, True, 95, "AUX44",
    > > > True,
    > > > > > > True, True _
    > > > > > > , True, , True
    > > > > > >
    > > > > > > What can I do?
    > > > > > >
    > > > > > > Thanks.
    > > > > >
    > > > > >
    > > > > >
    > > >
    > > >
    > > >

    >
    >
    >


+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1