Modify Existing Macro or Start Fresh?

Err

Active Member
Joined
Nov 16, 2006
Messages
274
Here is a problem:

You get a report in one format from someone every-so-often. The report as it stands is incomprehensible to most humans. Your boss and your coworkers ask you to convert it into a nice legible Excel spreadsheet.

So you do. You write a macro to sort through the ugly text file and automatically convert it into an excel spreadsheet. Perhaps you are like me and create a routine that will examine all of the unconverted files -then convert the ones that aren't converted yet.

-Are you with me so far? Everything is going along fine until:

Someone changes the original report format.

Now you know the changes that have taken place AND you also know all the work that will go into changing the format again. IT IS SLIGHTLY EASIER TO START FRESH RATHER THAN CHANGE YOUR EXISTING PROCEDURE.

What do you do? (Keep in mind that they might change it again).
 

Excel Facts

What is the shortcut key for Format Selection?
Ctrl+1 (the number one) will open the Format dialog for whatever is selected.
Every now and again I re-write my code for reports which haven't even changed. Usually because I pick up a tip from the forum which makes me realise I can do something much more efficiently.

Every time I create a new project, it is written better than my last, so I'm definately in the school of thought that you should start from scratch if a report format changes (plus it's a great excuse not to do any "real" work!!)
 
Upvote 0
Is there an option C? I would talk to the person providing the report to understand why it's changing in the first place and see what we can do to stop that nonsense (making/agreeing on templates, etc.).
 
Upvote 0
You're definitely better off agreeing on a set starting point. But, if you do need to redo it, do it from scratch. You could end up with a cleaner result.

Denis
 
Upvote 0
Is there an option C? I would talk to the person providing the report to understand why it's changing in the first place and see what we can do to stop that nonsense (making/agreeing on templates, etc.).

You must work in the efficient private sector. Technically I work in private sector but one ancillary to the Public Sector. -Very inefficient.

Just imagine that if suddenly you got transfered to working on a project for the post office. They change the format of a file... if you want to talk about anything -you get to leave voicemail which is never returned. You might get to fill out a request form asking to change the format back but if they do -some other contractor somewhere is upset.
 
Upvote 0
Simple matrix<ul>[*]x axis = How often do you anticipate change?<ul>[*]Once in a blue moon --> Every time I come back from the can[/list][*]y axis = How big o' PITA is it to handle changes to report layout?<ul>[*]Skeeter bite --> Flaming Hemorr....[/list][/list]
  • If bottom left quadrant - just patch it and get on down the road.
  • If top right, tear out to the foundation and re-build with a flexible structure that is highly modular and uses things like enumerated constants for column positions or import definitions so that in the future all you need to do is update the definitions and baddabingbaddaboom, yer done.
  • Top-Left or Bottom-Right use yer judgement or flip a coin...
 
Upvote 0
Interesting Poll.

Over the past couple of weeks I've been reworking a lot of stuff I've done and found myself competent enough to rewrite a lot of the macros I clubbed together when I was just starting out and am quite proud of my little babies who more or less all work together now and make my life a whole lot easier...

I think if you see potential in making an improvement here or there then, its worth doing if only for your own satisfaction and you will probably pick up a few new tricks on the way.

That said there is always the theory of, if it aint broke .. Don't fix it ;)

I've learnt many a lesson the hard way :lol:
 
Upvote 0

Forum statistics

Threads
1,225,327
Messages
6,184,302
Members
453,227
Latest member
Slainte

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top