Find Jobs
Hire Freelancers

Code Shortening

$10-30 AUD

Closed
Posted about 3 years ago

$10-30 AUD

Paid on delivery
Hi, I am reasonably OK with VBA. I have attached a piece of code that I would like to be shorter for processing speed and reduced size on disk. As you can see the code is repetitive and with some existing structures. The code is currently (5) long. The end code will need to be 40 long. A "For iIndexA = 0 to 39" may work but I am not sure on what I do with iIndexA to make it concatenate with the .txtComp each loop time to form .txtComp00 and then .txtComp01 and son on. iIndexA will also need a leading zero for the first 10 loops of the 40 long for Next.
Project ID: 29726516

About the project

7 proposals
Remote project
Active 3 yrs ago

Looking to make some money?

Benefits of bidding on Freelancer

Set your budget and timeframe
Get paid for your work
Outline your proposal
It's free to sign up and bid on jobs
7 freelancers are bidding on average $29 AUD for this job
User Avatar
Hello, I've read your project requirements thoroughly. It's quite an easy task and I can achieve this due to my experience with VBA script. It will be quick and accurate. I will start immediately and complete it within a few hours. If interested, we can discuss this further on chat.
$30 AUD in 1 day
4.5 (22 reviews)
4.7
4.7
User Avatar
Hey, 1) You wrote - > I have attached a piece of code that I would like to be shorter for processing speed Then mentioned switching to a FOR loop - > "For iIndexA = 0 to 39" You have 40 things to do. Writing each of the 40 tasks separately, or putting them in a loop, is *the same work*. The code will do these 40 things, one after another, either way. Rewriting code this way will *not* make anything faster, regardless of loop type. 2) The code gets values from a range of cells, then shows them in a form, 40 times. This is trivial and will execute in, say, 1 second. A 50% improvement would go from 1 second to half. Who would notice? Unless there's something else going on, or a problem, improving performance for this particular task seems like flogging a dead horse. An obvious thing would be to read data once and iterate that instead but the improvement might be marginal. 3) You mention - > and reduced size on disk Your existing logic is 6 lines. * 40 is 240 lines total, so roughly 20kb. Rewriting code as a loop will save you roughly 19.5k. Tiny. Usually an Excel file is actually internally a zip file, so you would save even less. Remember also that files are physically stored in chunks. These chunks can be larger than 19.5k so there might be no physical space saved at all. A loop would be more readable but not inherently better. Iterating form controls might be smaller. But the stated goals seem unrealistic. Oh yeah, there might be a bug - the code never unticks.
$10 AUD in 7 days
4.9 (3 reviews)
3.8
3.8
User Avatar
Hello, Sir. Expert of Excel VBA is here. I've gone through your project requirement and found my skill best suited in this one. I am familiar with technologies such as C++, VB, MS Office, Database Programming, Data Processing. I am the best suitable candidate to serve you. If you hire me, I will provide you good result. Let's discuss details about your job in chat. Thanks, Good luck.
$30 AUD in 1 day
4.5 (15 reviews)
3.9
3.9
User Avatar
Hi I gone through your code. Why can't we try do while instead of for loop. If you can give me your file I can try it out. Please initiate Chat to discuss.
$25 AUD in 1 day
5.0 (7 reviews)
3.0
3.0
User Avatar
Dear. ........................................ I am ready to start the task. please check my review. If you want to work with me, it is my pleasure. Let's start. ....................... Thanks.
$60 AUD in 1 day
5.0 (1 review)
0.4
0.4
User Avatar
I have had extensive experience with VBA and should be able to optimise the code for you. To get a better understanding of the work that will needed to be done I will need to have a look at the current vba project to determine what controls you are using. Once I have that information I am confident I'll be able to complete the project quickly for you. Please feel free to message me if you would like additional information. Best Regards Josh
$30 AUD in 1 day
0.0 (0 reviews)
0.0
0.0
User Avatar
Hi, i'm an informatyic engineer with more than 15 years of experience, i think that i can do this worok for you. If you are intersted, please contact me in private. Thank you
$20 AUD in 7 days
0.0 (0 reviews)
0.0
0.0

About the client

Flag of AUSTRALIA
Sydney, Australia
0.0
0
Member since Mar 30, 2021

Client Verification

Thanks! We’ve emailed you a link to claim your free credit.
Something went wrong while sending your email. Please try again.
Registered Users Total Jobs Posted
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Loading preview
Permission granted for Geolocation.
Your login session has expired and you have been logged out. Please log in again.