Automatic smart view hyperion refresh with VBA

Yuriy

New Member
Joined
Jul 18, 2012
Messages
3
maybe someone could help me to understand, what I'm doing wrong, as I'm stuck.. In general, I have a process, where I have an .vbs file, that triggers macro file, which makes connection to Hyperion and refreshes sheets.

For some reason, when I'm triggering that macro, it always asks me to enter credentials, even if I've declared them (which of course crushes automation).
Currently I have such code - two declarations:
<code style="margin: 0px; padding: 0px; border: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; line-height: inherit; font-family: Consolas, Menlo, Monaco, "Lucida Console", "Liberation Mono", "DejaVu Sans Mono", "Bitstream Vera Sans Mono", "Courier New", monospace, sans-serif; vertical-align: baseline; box-sizing: inherit; white-space: inherit;">DeclareFunction HypMenuVRefreshAll Lib"HsAddin.dll"()AsLong
DeclareFunction HypConnect Lib"HsAddin"(ByVal vtSheetName AsVariant,ByVal vtUserName AsVariant,ByVal vtPassword AsVariant,ByVal vtFriendlyName AsVariant)AsLong

</code>and then refresh happens with such part:
<code style="margin: 0px; padding: 0px; border: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; line-height: inherit; font-family: Consolas, Menlo, Monaco, "Lucida Console", "Liberation Mono", "DejaVu Sans Mono", "Bitstream Vera Sans Mono", "Courier New", monospace, sans-serif; vertical-align: baseline; box-sizing: inherit; white-space: inherit;">

Public
Sub Connect_OBIEE()

Dim wsSheet As Worksheet


ForEach wsSheet In ActiveWorkbook.Worksheets
x
= HypConnect(wsSheet.Name,"my_login<login>"</login>,"my_pass","connection_name<name of="" connection="">"</name>)
Next wsSheet

lngReturn
= HypMenuVRefreshAll()

End Sub

</code>How can I avoid the connection pop-up window, where it asks again my credentials, which if I will enter, will of course be working fine and then everything goes as I need..
So the general point is here, that my vbs file, that triggers macro, should enter everything automatically, refresh files, save and close, without these popu-ups.
Any suggestions?

 

Excel Facts

Highlight Duplicates
Home, Conditional Formatting, Highlight Cells, Duplicate records, OK to add pink formatting to any duplicates in selected range.

Forum statistics

Threads
1,214,932
Messages
6,122,334
Members
449,077
Latest member
Jocksteriom

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top