You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Bloomberg VBA证券价格导入宏突发失效求助

Hey there, sorry to hear your Bloomberg import macro suddenly stopped working after months of smooth running! Let’s walk through some troubleshooting steps to get it back up and running.

Troubleshooting Your Broken Bloomberg Import Macro

First, Rule Out Simple Terminal/Add-in Glitches

These are the easiest fixes to check first:

  • Restart your entire stack: Close Excel, shut down the Bloomberg Terminal app, and restart your computer. Temporary cache or connection blips often cause sudden failures like this.
  • Verify the Bloomberg Excel Add-in is active:
    1. Open Excel, go to File > Options > Add-ins
    2. Look for the Bloomberg Excel Add-in under Active Application Add-ins. If it’s in the Inactive list, click Go... at the bottom, check the box for the Bloomberg add-in, and hit OK.
  • Test a manual Bloomberg function: Open a blank Excel sheet and type a basic Bloomberg formula like =BDP("AAPL US Equity", "PX_LAST"). If this returns #N/A or an error, the problem is with your Bloomberg Terminal connection, not the macro itself—reach out to Bloomberg support if that’s the case.

Dig into the Suspected Bloomberg Command Issue

Since you think the price extraction command is the culprit, let’s dive deeper:

  • Check for Bloomberg API changes: Bloomberg occasionally updates their function syntax or field names. Type API <GO> in your Bloomberg Terminal to pull up the latest documentation, then compare the commands in your macro (like BDP, BDH, or any custom Bloomberg calls) to the current specs. For example, a niche price field might have been renamed, though this is rare for common fields like last price.
  • Validate ticker inputs: If your macro pulls tickers from a sheet, double-check that none of the tickers have changed (e.g., a company rebranded or switched exchanges). A single invalid ticker can crash the whole macro.

Use Your Error Message & Code Snippets to Narrow It Down

You mentioned the macro aborts with an error and shared a snippet of the code—let’s leverage that:

  • Share the exact error details: Was it a runtime error (like Run-time error '1004')? Or a Bloomberg-specific cell error (like #NAME? or #REF!)? The exact error text will tell us if it’s a syntax issue, a permission problem, or a data retrieval failure.
  • Post the full failing code block: The snippet you shared starts with Dim path As...—if you can paste the rest of the code where the Bloomberg command is called (e.g., where it uses BDP or BDH), we can spot syntax mistakes or variable issues. For example, if a variable holding the ticker isn’t being populated correctly, that would break the command.

Quick Fix to Try If All Else Fails

If the add-in seems corrupted, you can reinstall it directly from the Bloomberg Terminal:

  1. Type EXCEL <GO> in the terminal
  2. Follow the prompts to repair or reinstall the Excel add-in—this will refresh the connection between Excel and Bloomberg.

内容的提问来源于stack exchange,提问作者Jeremie St-Jean

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.05.26 10:04:29