So, I am working on an Excel project that will load a C ++ dll using VBA. What I would like to do is be able to pass an Excel range without a specific type (data can be numeric or categorical) for a C ++ dll (the best way to describe my Excel range is with the variant
type).
So the steps probably include:
- Download dll in VBA
- Send the excel range to the dll (the range may contain columns of numbers and / or columns of rows)
- manage data from excel to dll file
I mean using the excel variant and the C ++ variant. But it is not clear to me how to use the C ++ variant, since I could not find good documents on it.
Another suggestion I received is COM programming.
My questions:
- Can a good soul possibly give me directions on how to act? (e.g. by providing a C ++ prototype and a simple example of how to handle the variant)
- Does anyone know any good documentation / tutorial on using C ++ options (and possibly in conjunction with VBA)?
- Is using COMs preferable for using VARIANTS if speed is a problem?
- Does the API use the C API?
UPDATE:
- The size of the ranges that I need to be manipulated can be large (~ 500,000 lines).
- Speed ββis a factor, so I would like to avoid unnecessary copying as much as possible.
source share