Jump to content

Generating Worksheets


Recommended Posts

What is the best way to generate worksheets using Python?

 

I've got it working using two nested for-loops and vs.SetWSCellFormulaN, but this runs very slowly -

 

I'm wondering if there's a way to programmatically generate a temporary CSV file and then import that?

 

 

Cheers

Link to comment

I have created some fairly large worksheets using SetWSCellFormulaN and have not found it excessively slow.

 

How big of worksheets are you trying to create? Where is the data coming from?

 

I'm sure you could write a delimited file and then import it, but I can't see that as actually being faster than an internal script.

Link to comment
14 hours ago, Pat Stanford said:

I have created some fairly large worksheets using SetWSCellFormulaN and have not found it excessively slow.

Depends on what you mean by "excessively slow".  I have removed, separated out, some WS creation because it slowed things down too much.  Unfortunately, the need for the WS creation remained, and was put in a separate command.  (When I could).  The speed problem came about when I was creating long list of havested information with concatenated data.  After several tests isolating the data collection, data concatenation, and writing the cells, writing the cells was the main drag on time.  Still it was the fastest way I had of making the lists I needed.  One could always try typing the data into a list of any kind by hand, to make one put up with a slow script.

 

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...