Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Excel VBA to INSERT columns
Message
De
01/12/2005 11:08:18
 
 
À
01/12/2005 08:32:52
Information générale
Forum:
Visual FoxPro
Catégorie:
Produits tierce partie
Versions des environnements
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Divers
Thread ID:
01073561
Message ID:
01073761
Vues:
22
Thank you Tamar!

My script now runs in under 5 minutes for a sheet 124 columns by 6966 rows, inserting/filling approximately 25 columns along the way!

Sure beats 1 hour PER insert alone!!!!!

cheers


>>Hi all,
>>
>>I've got the job of converting Excel sheets from customers into our system's tables.
>>The customer data could have come from anything, from an Excel spreadsheet(s) to FileMakerPro 'exported' to Excel or ???
>>
>>I thought I'd tackle the toughest job first... converting text fields larger than 254 characters into multiple adjacent columns of 254 chunks so that they can be re-assembled as memo fields later.
>>
>>After much trial and tribulation I've got some VBA code that does the job BUT the insertion of columns takes FOREVER. In my test worksheet with 6966 rows it takes ovr an HOUR to insert a SINGLE COLUMN.
>>
>>I captured a macro of doing an INSERT Column, which happens nice and fast, and found that the generated code was a Range("DT:DT").Select then INSERT(Select) or something close to that.
>>
>>The trouble is, I can't find the way to correctly identify the column that way for a RANGE.
>
>You'll want something like:
>
>oRange = oSheet.Columns[nColumn]
>oRange.Insert()
>
>Tamar
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform