Click here to Skip to main content
15,891,529 members

Welcome to the Lounge

   

For discussing anything related to a software developer's life but is not for programming questions. Got a programming question?

The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.

 
GeneralRe: For how much time I spend navel gazing about the way I code Pin
honey the codewitch30-Nov-21 6:17
mvahoney the codewitch30-Nov-21 6:17 
GeneralRe: For how much time I spend navel gazing about the way I code Pin
Greg Utas30-Nov-21 6:31
professionalGreg Utas30-Nov-21 6:31 
GeneralRe: For how much time I spend navel gazing about the way I code Pin
honey the codewitch30-Nov-21 6:35
mvahoney the codewitch30-Nov-21 6:35 
GeneralRe: For how much time I spend navel gazing about the way I code Pin
Gerry Schmitz30-Nov-21 10:36
mveGerry Schmitz30-Nov-21 10:36 
GeneralRe: For how much time I spend navel gazing about the way I code Pin
englebart30-Nov-21 13:33
professionalenglebart30-Nov-21 13:33 
GeneralRe: For how much time I spend navel gazing about the way I code Pin
honey the codewitch30-Nov-21 13:36
mvahoney the codewitch30-Nov-21 13:36 
GeneralRe: For how much time I spend navel gazing about the way I code Pin
Member 916705730-Nov-21 20:18
Member 916705730-Nov-21 20:18 
GeneralRe: For how much time I spend navel gazing about the way I code Pin
Jalapeno Bob30-Nov-21 22:03
professionalJalapeno Bob30-Nov-21 22:03 
I also have trouble remembering what I was doing in other modules. My solution is a little different from yours.

I keep a bound and page numbered notebook. In it, I record my thought processes as I break down a problem into solvable units. I repeat this decomposition until I have manageable units, each of which does one thing. At this point, I also plan my error and exception handling.

Then, I review the units. I group all the units that directly act on a given data structure into a single module. Typical entry points to these modules have names such as CreateInstance, DestroyInstance, GetPreviousInstance, GetNextInstance, SerializeInstance, DeSerializeInstance, one or more versions of FormatInstanceForPrinting, GetValueFromInstance, and PutValueIntoInstance, where "Instance" is the name of or shorthand for the given data structure.

All of the input/output routines are placed in one stream dependent module modules. One for the main window. Each subordinate window has their own module, with a separate business logic module. One module for the printer. One module for each file that needs to be read or written. One module for each database accessed.

Next, I review my previous libraries of code. Often, I have an existing module that I can directly use or use with a little rewriting. Some I have used so often, I have created a .dll for each.

Now, I begin writing code. Into the top of each module, I copy the design notes from my notebook into a comment block. First, the missing I/O routines. Then, the main window with its controls, followed by the subordinate windows with their controls. At this point, I can demonstrate the flow of control through the windows to the customer to get their feedback. Lastly, I write the business logic modules and tie the whole program together.

After a little "alpha testing," I ask the customer to provide some real users to do some "beta testing." When the customer is happy, the code is done.

Having the comment blocks in each module refreshes my memory and provides a notebook number and page number to look up my thinking when I wrote the code. This really simplifies code maintenance.

The notebook not only documents my design, but also the problems I encountered and the dead ends I reached while designing the program. It also records where I was at the end of the day or when I have to put the project aside for some dumb meeting or a higher priority task.

__________________
Lord, grant me the serenity to accept that there are some things I just can’t keep up with, the determination to keep up with the things I must keep up with, and the wisdom to find a good RSS feed from someone who keeps up with what I’d like to, but just don’t have the damn bandwidth to handle right now.
© 2009, Rex Hammock


GeneralRe: For how much time I spend navel gazing about the way I code Pin
honey the codewitch30-Nov-21 23:10
mvahoney the codewitch30-Nov-21 23:10 
GeneralRe: For how much time I spend navel gazing about the way I code Pin
Jalapeno Bob2-Dec-21 20:04
professionalJalapeno Bob2-Dec-21 20:04 
GeneralRe: For how much time I spend navel gazing about the way I code Pin
BillWoodruff30-Nov-21 23:28
professionalBillWoodruff30-Nov-21 23:28 
GeneralRe: For how much time I spend navel gazing about the way I code Pin
Cpichols1-Dec-21 1:59
Cpichols1-Dec-21 1:59 
GeneralRe: For how much time I spend navel gazing about the way I code Pin
MKJCP1-Dec-21 4:00
MKJCP1-Dec-21 4:00 
GeneralRe: For how much time I spend navel gazing about the way I code Pin
Matt McGuire1-Dec-21 4:54
professionalMatt McGuire1-Dec-21 4:54 
GeneralRe: For how much time I spend navel gazing about the way I code Pin
MikeTheFid1-Dec-21 5:09
MikeTheFid1-Dec-21 5:09 
GeneralRe: For how much time I spend navel gazing about the way I code Pin
Martin ISDN1-Dec-21 5:40
Martin ISDN1-Dec-21 5:40 
GeneralCCC 30-11-2021 Pin
pkfox29-Nov-21 21:28
professionalpkfox29-Nov-21 21:28 
GeneralRe: CCC 30-11-2021 Pin
Peter_in_278029-Nov-21 22:29
professionalPeter_in_278029-Nov-21 22:29 
GeneralRe: CCC 30-11-2021 - Winner !!! Pin
pkfox29-Nov-21 22:57
professionalpkfox29-Nov-21 22:57 
Questioncode sexiness question Pin
Super Lloyd29-Nov-21 19:57
Super Lloyd29-Nov-21 19:57 
AnswerRe: code sexiness question Pin
Rage29-Nov-21 20:05
professionalRage29-Nov-21 20:05 
GeneralRe: code sexiness question Pin
Super Lloyd29-Nov-21 20:13
Super Lloyd29-Nov-21 20:13 
GeneralRe: code sexiness question Pin
Rage29-Nov-21 20:19
professionalRage29-Nov-21 20:19 
GeneralRe: code sexiness question Pin
Super Lloyd29-Nov-21 20:29
Super Lloyd29-Nov-21 20:29 
AnswerRe: code sexiness question Pin
HobbyProggy29-Nov-21 20:30
professionalHobbyProggy29-Nov-21 20:30 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.