How do I verify that blpapi3.jar is included on MATLAB javaclasspath when using Datafeed Toolbox 4.5 (R2013a)?

56 views (last 30 days)
I receive the following error message when I use BLP to try to connect to the local Bloomberg server:
Error using blp (line 43)
Please verify that blpapi3.jar is included on MATLAB javaclasspath.
I would like to know how to perform the verification mentioned in the message.

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 13 Jul 2015
In order to connect to the local Bloomberg server using BLP in Datafeed Toolbox 4.5 (R2013a), the 'blpapi3.jar' file must be on the MATLAB Java class path. If this file already exists on the current machine, it can found in either the 'C:\blp\api\APIv3\JavaAPI\lib\blpapi3.jar' or the 'C:\blp\api\APIv3\JavaAPI\vX.X.X.X\lib\blpapi3.jar' directories. If the file does not already exist, it can be downloaded from the Bloomberg website as follows:
1. In a Bloomberg terminal, execute the following to navigate to the Desktop/Server API screen:
>> WAPI
2. Next, download the Desktop v3.x API.  To do this, click on the 'Download Software' link under 'Desktop API' as shown below.
This link will navigate to the following screen.  
Click on the 'Download' button next to the 'Desktop API' product.  This will download a file called 'NoAdmin_DesktopAPI_SDK.zip'.
3. Extract the contents of the downloaded file under 'C:\blp\'. If you already have a 'C:\blp\API', extract the contents of 'APIv3' here.  'APIv3' is one directory below the top level directory, 'API', in 'NoAdmin_DesktopAPI_SDK.zip'.  
Take note of where the 'blpapi3.jar' file is located.  It should be located under a path similar to 'C:\blp\api\APIv3\JavaAPI\vX.X.X.X\lib\blpapi3.jar'.
4. Once the 'blpapi3.jar' file is on your system, you must add it to the Java class path during start-up time.  In order to do this, create a file called 'startup.m' and add the following line:
 
javaaddpath('C:\blp\api\APIv3\JavaAPI\vX.X.X.X\lib\blpapi3.jar')
where the input string specifies the path to 'blapi3.jar' from step 3.
Save the 'startup.m' file at the location returned by executing the following command in the MATLAB Command Window:
>> userpath
 
5. Restart MATLAB.
  In order to use Bloomberg within MATLAB, you need to start BBComm which establishes a secure connection to the Bloomberg server. This program should be under C:\Bloomberg API\startBBComm.  You may notice that the first connection to Bloomberg needs several tries before it is successfully established.  You may also need to use a biometric fingerprint reader to log into your account. If you are having troubles logging into your Bloomberg account using the Bloomberg terminal, you should contact Bloomberg directly.

More Answers (2)

Anna Wang
Anna Wang on 9 Nov 2015
I'm using Matlab R2015b. When I downloaded NoAdmin_DesktopAPI_SDK folder, I cannot access API folder to copy the blpapi3.jar. Could you help?

Baha411
Baha411 on 29 Nov 2021
Edited: Baha411 on 29 Nov 2021
Hi. It is not easy to follow those instructions above. I just downloaded Matlab 2021b and I am having this error message below. Can you explain how I fix this step-by-step as if I know nothing about those websites (bloomberg) or terminals? Do I have to have a paid bloomberg account? This is not straightforward for someone new in this. I apprecaite if anyone could explain.
>> c = blp;
Error using blp (line 67)
Verify that blpapi3.jar included on MATLAB javaclasspath.

Products


Release

R2013a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!