Hi all,
I find myself attempting to learn VBA bit by bit, kicking myself in the butt as I had chosen to ignore excel through my college (NOBODY USES MATLAB (EXCEPT R&D) PROFESSORS!)
Anyway, on to my issue - I know how to approach this in a programming sense, I just have no idea how to translate it into VBA.
This is my scenario -
I have a bunch of data that I import from a .csv file. Then, on the main sheet titled (Schedule). This occupies cols A through I. Columns K, L are calculated values based upon the previous columns.
I now run into the following issue: I created a calculations sheet, which is named after colA/B. I need to create this sheet for each row of data. This sheet is populated with data from cols A-L, then does some calculations which are sent back to the main sheet (Schedule) for the remaining columns M-Q.
Programming-wise, I'd probably treat it something like this (pseudocode)
What I'm having issues conceptualizing in vba is keeping track of the index - is this even needed? How would I go about populating the calcs sheet with data from the correct row?
If this is extremely vague, let me know and I can try to explain more or post the spreadsheet.
I find myself attempting to learn VBA bit by bit, kicking myself in the butt as I had chosen to ignore excel through my college (NOBODY USES MATLAB (EXCEPT R&D) PROFESSORS!)
Anyway, on to my issue - I know how to approach this in a programming sense, I just have no idea how to translate it into VBA.
This is my scenario -
I have a bunch of data that I import from a .csv file. Then, on the main sheet titled (Schedule). This occupies cols A through I. Columns K, L are calculated values based upon the previous columns.
I now run into the following issue: I created a calculations sheet, which is named after colA/B. I need to create this sheet for each row of data. This sheet is populated with data from cols A-L, then does some calculations which are sent back to the main sheet (Schedule) for the remaining columns M-Q.
Programming-wise, I'd probably treat it something like this (pseudocode)
Code:
data = dataread(export.csv)
z = size(data)
for i = 1:z
% do calculations for cols K/L
copysheet(i)
% do calcs for remaining cols
end
What I'm having issues conceptualizing in vba is keeping track of the index - is this even needed? How would I go about populating the calcs sheet with data from the correct row?
If this is extremely vague, let me know and I can try to explain more or post the spreadsheet.
Last edited: