Two part question, if that's allowed. I have a macro named NewMarginPlacement that calls an InputBox series designed to capture seven variables, store those variables in an object called NMP (clsNMP), that is ultimately placed into a collection called NMPs (clsNMPs).
My first question involves the Add to Collection Method. I'm running this code in the NewMarginPlacement Sub:
NMPs.Add sFirstName, sLastName, sClientName, sPayRate, sBillRate, sEmployStatus, sSplitPercent
'Adds NMP object variables into collection?
But I feel like it should be written as:
NMPs.Add cFirstName, cLastName, cClientName, cPayRate, cBillRate, cEmployStatus, cSplitPercent
'Adds NMP object variables into collection?
Instead I gives me a Compiler Error ByRef argument type mismatch. Can someone share some insight on how these variables are all working together?
Secondly, these objects and collections reset everytime I run the macro. I'm creating this collection to persisently store these objects between user sessions and I would like them to be shared with other sheets by storing the collection class in a library (txt file?), where do I go from here?
Bookmarks