Hi All,
I hope this is reasonably simple - but googling it shows a level of vba code I'm not capable of reading unfortunately - so I need a simpler explanation
I have a fully functioning bit of code that queries a SQL database. It works completely fine. However, I need to pass it on to our finance department who will be using it, and they aren't particularly technical. The code works fine ONLY if the "microsoft activex data objects 2.8 library" and "microsoft activex data objects recordset 2.8 library" references are checked in the tools option. I have zero faith in them wanting to do this every time they add this code to a workbook, so I want to have the sub include it as part of it's process.
Is this possible? and secondly, how do you do it?
It seems to involve the .references.addfromfile command, but I'm really struggling to parse from the code examples I've been able to find exactly how this works so I can substitute in the correct values.
Any help is gratefully received.
Thanks
I hope this is reasonably simple - but googling it shows a level of vba code I'm not capable of reading unfortunately - so I need a simpler explanation
I have a fully functioning bit of code that queries a SQL database. It works completely fine. However, I need to pass it on to our finance department who will be using it, and they aren't particularly technical. The code works fine ONLY if the "microsoft activex data objects 2.8 library" and "microsoft activex data objects recordset 2.8 library" references are checked in the tools option. I have zero faith in them wanting to do this every time they add this code to a workbook, so I want to have the sub include it as part of it's process.
Is this possible? and secondly, how do you do it?
It seems to involve the .references.addfromfile command, but I'm really struggling to parse from the code examples I've been able to find exactly how this works so I can substitute in the correct values.
Any help is gratefully received.
Thanks