I have some C++ code that includes a method called CreateDirectory(). Previously the code only used STL and Boost, but I recently had to include
CreateDirectory().
You could create a module whose sole purpose is to #include and look up CSIDL_LOCAL_APPDATA wrapped in a function.
#include
int get_CSIDL_LOCAL_APPDATA(void) { return CSIDL_LOCAL_APPDATA; }
btw, Well done for working out what happened!