VBA data storage the text box way
-
Me (paraphrasing): No, colleague, putting each one of a list of 24 values into its own text box is not an efficient method of data storage. How about putting them into an array, then you can reference them by number. Colleague: I didn't know about arrays. Me: (stunned silence) Colleague: I use
goto
s to get to the code that reads data from the right text box. Me: Modern programming recommendations are that you keep usage ofgoto
s to a minimum because it makes determining program flow very difficult. Colleague: Really? Me: :doh: -
Me (paraphrasing): No, colleague, putting each one of a list of 24 values into its own text box is not an efficient method of data storage. How about putting them into an array, then you can reference them by number. Colleague: I didn't know about arrays. Me: (stunned silence) Colleague: I use
goto
s to get to the code that reads data from the right text box. Me: Modern programming recommendations are that you keep usage ofgoto
s to a minimum because it makes determining program flow very difficult. Colleague: Really? Me: :doh:Is the colleague actually a programmer? If so, I echo said "stunned silence".
-
Let's just say that somebody should
goto
Burger King. ;) -
Let's just say that somebody should
goto
Burger King. ;)Me, Me,,, I'm hungry But my boss is staring this way :~
-
Let's just say that somebody should
goto
Burger King. ;) -
Let's just say that somebody should
goto
Burger King. ;)Ok, you convinced me. I will do that right after work.
"I just exchanged opinions with my boss. I went in with mine and came out with his." - me, 2011 ---
I am endeavoring, Madam, to construct a mnemonic memory circuit using stone knives and bearskins - Mr. Spock 1935 and me 2011 -
Me (paraphrasing): No, colleague, putting each one of a list of 24 values into its own text box is not an efficient method of data storage. How about putting them into an array, then you can reference them by number. Colleague: I didn't know about arrays. Me: (stunned silence) Colleague: I use
goto
s to get to the code that reads data from the right text box. Me: Modern programming recommendations are that you keep usage ofgoto
s to a minimum because it makes determining program flow very difficult. Colleague: Really? Me: :doh:So it sounds like he has effectively implemented his own array, albeit with poor choices in how to store and access the data, but I think that shows good logic. After all, he doesn't know what an array is, yet he has decided an array style function is the best approach. He may not have the "experience" of a great developer, but being able to think for himself is a good thing. I think too many programmers are around that just do what the book says, and therefore struggle to be creative when a need arises for something that has yet to be documented.
I may or may not be responsible for my own actions
-
Me (paraphrasing): No, colleague, putting each one of a list of 24 values into its own text box is not an efficient method of data storage. How about putting them into an array, then you can reference them by number. Colleague: I didn't know about arrays. Me: (stunned silence) Colleague: I use
goto
s to get to the code that reads data from the right text box. Me: Modern programming recommendations are that you keep usage ofgoto
s to a minimum because it makes determining program flow very difficult. Colleague: Really? Me: :doh: -
So it sounds like he has effectively implemented his own array, albeit with poor choices in how to store and access the data, but I think that shows good logic. After all, he doesn't know what an array is, yet he has decided an array style function is the best approach. He may not have the "experience" of a great developer, but being able to think for himself is a good thing. I think too many programmers are around that just do what the book says, and therefore struggle to be creative when a need arises for something that has yet to be documented.
I may or may not be responsible for my own actions
If the "colleague" was a high school intern who has never taken a programming class, then yes their logical abilities show promise and they could be trained. However, if this is someone with a degree in programming then they really missed some very basic stuff. :omg:
Just because the code works, it doesn't mean that it is good code.
-
That is a serious gap in knowledge! :wtf: Did this person graduate with a programming related degree.
Just because the code works, it doesn't mean that it is good code.
The degree bit is not relevant - I'm self-taught, but can read books too. This is really really basic.