Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Essbase api error 1030001 after working for a while

203 views
Skip to first unread message

David...@slkp.com

unread,
Oct 16, 2000, 8:58:47 PM10/16/00
to
I am using the Essbase API's in Excel and my code is working just fine.
I have declare hCtx in my module, and use the autologin to set it, and
I get a contex handle. The code uses it to copy some essbase data
around and recalc the cube. The problem is if I don't do anything for
some period of time (like I go to lunch) I seem to loose the context
handle (hCtx), am I just getting logged out by the server? Should I
just test for the condition and relogin or is there a better solution.

Thanks,
David


Sent via Deja.com http://www.deja.com/
Before you buy.

Tim Tow, CPA MCSD

unread,
Oct 17, 2000, 3:00:00 AM10/17/00
to
<David...@slkp.com> wrote in message news:8sg885$gbj$1...@nnrp1.deja.com...

> I am using the Essbase API's in Excel and my code is working just fine.
> I have declare hCtx in my module, and use the autologin to set it, and
> I get a contex handle. The code uses it to copy some essbase data


Hi David,

I didn't find the documentation for 1030001 (it's not in the error
message.txt file included with the API).. What is the error message, if
any, on the server?

One thing I do see from your comments.. From Excel, you should use the
EssVGetHctxFromSheet to get a context handle from a connected Excel sheet...
Using EsbAutoLogin from Excel is not supported..

Tim

Tim Tow, CPA MCSD
Microsoft MVP - Excel
Applied OLAP, Inc

David...@slkp.com

unread,
Oct 17, 2000, 3:00:00 AM10/17/00
to
Hi Tim,
Thanks for the reply, and you are correct there is no message for
1030001. I had found a message on Deja from 1999 that eluded to the
fact that you get 1030001 when you have lost your context handle, mine
goes to 0 on me for no apparent reason.
I took your suggestion and change my code to use essvgethctxfromsheet
like this...

If hCtx = 0 Then hCtx = EssVGetHctxFromSheet("[" &
application.ActiveWorkbook.Name & "]" & ActiveSheet.Name)

it seems to get a handle, but when I call the api
sts = EsbCalc(hCtx, ESB_TRUE, sCalcScript)
It doesn't seem to do anything, it returns immediately like it's
ignoring my request, the return value in sts is 0.

Is EsbCalc supported in Excel?
If not how do you run a dynamically built calc script?

Thanks for the help,
-David


In article <8shd5q$f11$1...@nntp9.atl.mindspring.net>,


"Tim Tow, CPA MCSD" <tim...@appliedolap.com> wrote:
> <David...@slkp.com> wrote in message news:8sg885
$gbj$1...@nnrp1.deja.com...

> > I am using the Essbase API's in Excel and my code is working just
fine.
> > I have declare hCtx in my module, and use the autologin to set it,
and
> > I get a contex handle. The code uses it to copy some essbase data
>

> Hi David,
>
> I didn't find the documentation for 1030001 (it's not in the error
> message.txt file included with the API).. What is the error
message, if
> any, on the server?
>
> One thing I do see from your comments.. From Excel, you should use
the
> EssVGetHctxFromSheet to get a context handle from a connected Excel
sheet...
> Using EsbAutoLogin from Excel is not supported..
>
> Tim
>
> Tim Tow, CPA MCSD
> Microsoft MVP - Excel
> Applied OLAP, Inc
>
>

David...@slkp.com

unread,
Oct 17, 2000, 3:00:00 AM10/17/00
to
I forgot to mention that after I use essVgetHctxFromSheet to get the
hCtx and I then call EsbCalc with that handle, I do make calls to
EsbGetProcessState and it returns ESB_STATE_DONE after the first call,
and it used to take it a while.

Thanks,
-David

In article <8shmu4$k7e$1...@nnrp1.deja.com>,


David...@slkp.com wrote:
> Hi Tim,
> Thanks for the reply, and you are correct there is no message for
> 1030001. I had found a message on Deja from 1999 that eluded to the
> fact that you get 1030001 when you have lost your context handle, mine
> goes to 0 on me for no apparent reason.
> I took your suggestion and change my code to use essvgethctxfromsheet
> like this...
>
> If hCtx = 0 Then hCtx = EssVGetHctxFromSheet("[" &
> application.ActiveWorkbook.Name & "]" & ActiveSheet.Name)
>
> it seems to get a handle, but when I call the api
> sts = EsbCalc(hCtx, ESB_TRUE, sCalcScript)
> It doesn't seem to do anything, it returns immediately like it's
> ignoring my request, the return value in sts is 0.
>
> Is EsbCalc supported in Excel?
> If not how do you run a dynamically built calc script?
>
> Thanks for the help,
> -David
>
> In article <8shd5q$f11$1...@nntp9.atl.mindspring.net>,
> "Tim Tow, CPA MCSD" <tim...@appliedolap.com> wrote:
> > <David...@slkp.com> wrote in message news:8sg885
> $gbj$1...@nnrp1.deja.com...

> > > I am using the Essbase API's in Excel and my code is working just
> fine.
> > > I have declare hCtx in my module, and use the autologin to set it,
> and
> > > I get a contex handle. The code uses it to copy some essbase data
> >

> > Hi David,
> >
> > I didn't find the documentation for 1030001 (it's not in the error
> > message.txt file included with the API).. What is the error
> message, if
> > any, on the server?
> >
> > One thing I do see from your comments.. From Excel, you should
use
> the
> > EssVGetHctxFromSheet to get a context handle from a connected Excel
> sheet...
> > Using EsbAutoLogin from Excel is not supported..
> >
> > Tim
> >
> > Tim Tow, CPA MCSD
> > Microsoft MVP - Excel
> > Applied OLAP, Inc
> >
> >
>

David...@slkp.com

unread,
Oct 17, 2000, 3:00:00 AM10/17/00
to
Hi Tim,
Thanks for the reply, and you are correct there is no message for
1030001. I had found a message on Deja from 1999 that eluded to the
fact that you get 1030001 when you have lost your context handle, mine
goes to 0 on me for no apparent reason.
I took your suggestion and change my code to use essvgethctxfromsheet
like this...

If hCtx = 0 Then hCtx = EssVGetHctxFromSheet("[" &
application.ActiveWorkbook.Name & "]" & ActiveSheet.Name)

it seems to get a handle, but when I call the api
sts = EsbCalc(hCtx, ESB_TRUE, sCalcScript)

it doesn't seem to do anything. sts is 0.

After I call EsbCalc , I do make calls to


EsbGetProcessState and it returns ESB_STATE_DONE after the first call,

and it used to take it a while, it is like the calc does not work but
I'm not getting an error.

Is EsbCalc supported in Excel?
If not how do you run a dynamically built calc script?

Thanks for the help,
-David


In article <8shd5q$f11$1...@nntp9.atl.mindspring.net>,
"Tim Tow, CPA MCSD" <tim...@appliedolap.com> wrote:
> <David...@slkp.com> wrote in message news:8sg885
$gbj$1...@nnrp1.deja.com...

> > I am using the Essbase API's in Excel and my code is working just
fine.
> > I have declare hCtx in my module, and use the autologin to set it,
and
> > I get a contex handle. The code uses it to copy some essbase data
>

> Hi David,
>
> I didn't find the documentation for 1030001 (it's not in the error
> message.txt file included with the API).. What is the error
message, if
> any, on the server?
>
> One thing I do see from your comments.. From Excel, you should use
the
> EssVGetHctxFromSheet to get a context handle from a connected Excel
sheet...
> Using EsbAutoLogin from Excel is not supported..
>
> Tim
>
> Tim Tow, CPA MCSD
> Microsoft MVP - Excel
> Applied OLAP, Inc
>
>

Ernesto Contreras

unread,
Oct 19, 2000, 3:00:00 AM10/19/00
to

The Context Handle for Essbase & the API are different!, you need a
different context handle for API calls than the one used by Excel..

I bet that your problem lies in the fact that after certain amount of time
accounts are disconnected from the Server, the setting can be set with the
app/manager

The only solution is
a) change the setting on the server
b) Or in your error handling routines catch the error and reconect the
session using the original user/password..

Regards
Ernesto A. Contreras
econt...@hotmail.com


<David...@slkp.com> wrote in message news:8shq28$n0h$1...@nnrp1.deja.com...


> Hi Tim,
> Thanks for the reply, and you are correct there is no message for
> 1030001. I had found a message on Deja from 1999 that eluded to the
> fact that you get 1030001 when you have lost your context handle, mine
> goes to 0 on me for no apparent reason.
> I took your suggestion and change my code to use essvgethctxfromsheet
> like this...
>
> If hCtx = 0 Then hCtx = EssVGetHctxFromSheet("[" &
> application.ActiveWorkbook.Name & "]" & ActiveSheet.Name)
>
> it seems to get a handle, but when I call the api
> sts = EsbCalc(hCtx, ESB_TRUE, sCalcScript)
> it doesn't seem to do anything. sts is 0.
>
> After I call EsbCalc , I do make calls to
> EsbGetProcessState and it returns ESB_STATE_DONE after the first call,
> and it used to take it a while, it is like the calc does not work but
> I'm not getting an error.
>
> Is EsbCalc supported in Excel?
> If not how do you run a dynamically built calc script?
>
> Thanks for the help,
> -David
>
>
> In article <8shd5q$f11$1...@nntp9.atl.mindspring.net>,
> "Tim Tow, CPA MCSD" <tim...@appliedolap.com> wrote:
> > <David...@slkp.com> wrote in message news:8sg885
> $gbj$1...@nnrp1.deja.com...

> > > I am using the Essbase API's in Excel and my code is working just
> fine.
> > > I have declare hCtx in my module, and use the autologin to set it,
> and
> > > I get a contex handle. The code uses it to copy some essbase data
> >

> > Hi David,
> >
> > I didn't find the documentation for 1030001 (it's not in the error
> > message.txt file included with the API).. What is the error
> message, if
> > any, on the server?
> >
> > One thing I do see from your comments.. From Excel, you should use
> the
> > EssVGetHctxFromSheet to get a context handle from a connected Excel
> sheet...
> > Using EsbAutoLogin from Excel is not supported..
> >
> > Tim
> >
> > Tim Tow, CPA MCSD
> > Microsoft MVP - Excel
> > Applied OLAP, Inc
> >
> >
>
>

Tim Tow, CPA MCSD

unread,
Oct 19, 2000, 3:00:00 AM10/19/00
to
<David...@slkp.com> wrote in message news:8shq28$n0h$1...@nnrp1.deja.com...
> fact that you get 1030001 when you have lost your context handle, mine
> goes to 0 on me for no apparent reason.
> I took your suggestion and change my code to use essvgethctxfromsheet
> like this...

Hmm..


> If hCtx = 0 Then hCtx = EssVGetHctxFromSheet("[" &
> application.ActiveWorkbook.Name & "]" & ActiveSheet.Name)

Personally, I would not use ActiveWorkbook and ActiveSheet to get these
unless you can guarantee that book/sheet is active.. I would create a
sheet object that refers to a specific sheet (and use the parent property to
get the workbook object it is contained in).. This probably isn't related
to what you are having a problem with here..

> it seems to get a handle, but when I call the api
> sts = EsbCalc(hCtx, ESB_TRUE, sCalcScript)
> it doesn't seem to do anything. sts is 0.

> After I call EsbCalc , I do make calls to
> EsbGetProcessState and it returns ESB_STATE_DONE after the first call,
> and it used to take it a while, it is like the calc does not work but
> I'm not getting an error.

Are you doing anything else in the code previous to this point that expects
you to retrieve from a buffer on the server? I have experienced a problem
similar to yours when I had such a buffer and I didn't get items until it
was "complete".


> Is EsbCalc supported in Excel?

I have done it many times.. Did you get the VB API source code samples
from our website? There are 2 presentations I gave a previous Hyperion
conferences with a bunch of source code (including calc examples)..

Tim Tow, CPA MCSD

unread,
Oct 19, 2000, 3:00:00 AM10/19/00
to

"Ernesto Contreras" <econt...@prodigy.net> wrote in message
news:8snsp5$6pjq$1...@newssvr05-en0.news.prodigy.com...

>
> The Context Handle for Essbase & the API are different!, you need a
> different context handle for API calls than the one used by Excel..

This is incorrect... You can use the EssVGetHctxFromSheet function to get
the context handle from an Excel-connected worksheet and use it for any API
call that requires a context handle *except* the functions to logoff (and
disconnect the sheet)..

David...@slkp.com

unread,
Oct 23, 2000, 3:00:00 AM10/23/00
to
Thank you very much for the help.
The problem was I was using ESB_TRUE for the call to EsbCalc but
ESB_TRUE was not being set to 1 when I set up my code to use
EssVGetHctxFromSheet. So it all works just fine, and I have decided it
is best to use ESB_YES, it's a constant.

I did have one other question, you had mentioned that EsbAutoLogin is
not supported in excel, I was hoping you might remember where you read
that (I have looked but could not find it), so I can explain/show it to
my manager, I think we have a beta licance for the toolkit and we will
need to get a real licance. It will be easer if I can show him in black
and white.

Thanks again,
-David

In article <8so90b$90g$1...@nntp9.atl.mindspring.net>,


"Tim Tow, CPA MCSD" <tim...@appliedolap.com> wrote:

> Tim
>
> Tim Tow, CPA MCSD
> Microsoft MVP - Excel
> Applied OLAP, Inc
>
>

Ernesto Contreras

unread,
Oct 23, 2000, 3:00:00 AM10/23/00
to

Thanks for clarifying the point, I used to program Essbase on version 3 and
4, and I don't remember seeing that function anywhere, but it appears I
should read the new manuals every now and then..

Ernesto Contreras

Tim Tow, CPA MCSD <tim...@appliedolap.com> wrote in message
news:8so93e$lfj$1...@slb3.atl.mindspring.net...


>
> "Ernesto Contreras" <econt...@prodigy.net> wrote in message
> news:8snsp5$6pjq$1...@newssvr05-en0.news.prodigy.com...
> >
> > The Context Handle for Essbase & the API are different!, you need a
> > different context handle for API calls than the one used by Excel..
>
> This is incorrect... You can use the EssVGetHctxFromSheet function to
get
> the context handle from an Excel-connected worksheet and use it for any
API
> call that requires a context handle *except* the functions to logoff (and
> disconnect the sheet)..
>

Tim Tow, CPA MCSD

unread,
Oct 24, 2000, 3:00:00 AM10/24/00
to
<David...@slkp.com> wrote in message news:8t2geg$rrd$1...@nnrp1.deja.com...

> The problem was I was using ESB_TRUE for the call to EsbCalc but
> ESB_TRUE was not being set to 1 when I set up my code to use

I have always thought that was incorrectly declared in the Essbase API
files, but have not been successful in getting it changed..


> I did have one other question, you had mentioned that EsbAutoLogin is
> not supported in excel, I was hoping you might remember where you read
> that (I have looked but could not find it), so I can explain/show it to

I don't remember exactly.. It may have been tech support or the manager
for the API product or it may have been published at some point.. It
shouldn't matter for you though, read on..

> my manager, I think we have a beta licance for the toolkit and we will
> need to get a real licance. It will be easer if I can show him in black
> and white.

Calling EsbCalc, or *any* other function from Excel using the API,
technically puts you into territory where the license to use the API is
required. Note that if someone else *writes* the code for you, say a
consultant, and that person/company is licensed to use the API, as all
Hyperion Alliance Partners are, then you would not require a license for the
API.. The safest bet would be to check with your Hyperion rep (although
they may not be aware of the details above; have them check with the legal
department <BigGrin>)

Tim
Applied OLAP, Inc (one of the 300+ Hyperion Alliance Partners!)

.

0 new messages