简体   繁体   English

有没有办法用宏运行同一个excel工作簿的多个实例?

[英]Any way to run multiple instances of the same excel workbook with macros?

I have a large macro enabled workbook that processes data and exports it in a usable format.我有一个启用宏的大型工作簿,它处理数据并以可用格式导出它。 Some of the data that it processes can be large and take a while to run through the workbook.它处理的一些数据可能很大并且需要一段时间才能运行工作簿。 I'd like to be able to open this workbook multiple times to process multiple data sets at once.我希望能够多次打开此工作簿以一次处理多个数据集。 Is there any way that this can be done?有什么办法可以做到这一点吗?

I am using a python 3 app that I developed to manage the books and am more than open to using other languages and software.我正在使用我开发的 python 3 应用程序来管理书籍,并且非常愿意使用其他语言和软件。

Think about your problem here.在这里想想你的问题。

Assuming the workbook that processes the data is essentially a model, with input and output, what you could simply do is make copies of that workbook ahead of i/o model run.假设处理数据的工作簿本质上是一个模型,具有输入和输出,您可以简单地做的是在 i/o 模型运行之前制作该工作簿的副本。

So you've gout 1-10,000 rows of data for Model1.xlsm 10,001-20,000 rows of data for Model2.xlsm.因此,您为 Model1.xlsm 输出了 1-10,000 行数据,为 Model2.xlsm 输出了 10,001-20,000 行数据。

Obviously this is hackneyed, but the fact that you have to do this with Excel and not just use python for calculation means this is probably the easiest way to overcome the problem.显然这是老生常谈,但事实上你必须用 Excel 来做这件事,而不仅仅是使用 python 进行计算,这意味着这可能是解决问题的最简单方法。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 运行同一个 Discord Bot 的多个实例的有效方法 (Discord) - Efficient Way to Run Multiple Instances of the Same Discord Bot (Discord) 有什么方法可以检测 excel 工作簿是否在 Python 或机器人框架中受密码保护? - Is there any way to detect if an excel workbook is password protected in Python or Robot framework? 如何异步运行同一个 class 的多个实例? - How to run multiple instances of the same class asynchrously? 加载同一图像的多个实例的最佳方法 - Optimal way to load multiple instances of the same image Python在Excel的多个实例中控制宏 - Python to control macros in mutliple instances of Excel 使用 Pandas to pd.read_excel() 为同一工作簿的多个工作表 - Using Pandas to pd.read_excel() for multiple worksheets of the same workbook 使用Python创建工作簿时Excel宏不可用 - Excel Macros Not Available When Workbook is Created Using Python 如何同时运行selenium的多个实例 - Python - How to run multiple instances of selenium at the same time - Python 是否可以在单个 GRPC 服务器上运行同一服务的多个实例? - Is it possible to run multiple instances of same service on single GRPC server? 与同一个python脚本的多个实例共享变量的最佳方法 - Best way to share a variable with multiple instances of the same python script
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM