Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Essbase Error handling through VBA

I'm looking for some error handling help with Essbase through VBA.
Specifically, I'm prompting the user for an ID and Password, and need to be
able to cleanly terminate the code (or some other error handling response) if
the ID and/or password they enter isn't a valid Essbase ID or password. I can
address "Cancel" quite readily, but can't find any direction on other
possible responses.

Any ideas? thanks.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,939
Default Essbase Error handling through VBA

You are not so much looking for error handling as you are for invalid login
passwords. To that end the Essbase API "EssConnect" returns 0 for a
successful connection and other numbers if unsuccessful. So it is just a
matter of catching the return code and evaluating if it is 0.

dim lngConnect as Long

lngConnnect = EssConnect(sheetName, username, password, server, application,
database)

if lngConnect < 0 then
msgbox "Sorry Can't Connect"
else
'your code here...
end if
--
HTH...

Jim Thomlinson


"RPC@Frito" wrote:

I'm looking for some error handling help with Essbase through VBA.
Specifically, I'm prompting the user for an ID and Password, and need to be
able to cleanly terminate the code (or some other error handling response) if
the ID and/or password they enter isn't a valid Essbase ID or password. I can
address "Cancel" quite readily, but can't find any direction on other
possible responses.

Any ideas? thanks.

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Essbase Error handling through VBA

That was exactly what I needed. Thank you.

"Jim Thomlinson" wrote:

You are not so much looking for error handling as you are for invalid login
passwords. To that end the Essbase API "EssConnect" returns 0 for a
successful connection and other numbers if unsuccessful. So it is just a
matter of catching the return code and evaluating if it is 0.

dim lngConnect as Long

lngConnnect = EssConnect(sheetName, username, password, server, application,
database)

if lngConnect < 0 then
msgbox "Sorry Can't Connect"
else
'your code here...
end if
--
HTH...

Jim Thomlinson


"RPC@Frito" wrote:

I'm looking for some error handling help with Essbase through VBA.
Specifically, I'm prompting the user for an ID and Password, and need to be
able to cleanly terminate the code (or some other error handling response) if
the ID and/or password they enter isn't a valid Essbase ID or password. I can
address "Cancel" quite readily, but can't find any direction on other
possible responses.

Any ideas? thanks.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
UniquifyForUser error for Essbase AddIN John Excel Worksheet Functions 1 January 24th 09 01:43 PM
Error handling error # 1004 Run-time error [email protected] Excel Programming 3 May 20th 08 02:23 PM
Set Error handling INSIDE error-trap Michelle Excel Programming 6 May 3rd 08 03:30 PM
Error Handling - On Error GoTo doesn't trap error successfully David Excel Programming 9 February 16th 06 05:59 PM
Error handling with a handling routine ben Excel Programming 0 March 15th 05 03:01 PM


All times are GMT +1. The time now is 06:34 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"