Is it possible to write to custom field from within VBA code?
Nope, custom license fields are read-only from within your app.
If you want to write a field you'll have to...
Note: you can't use the web API directly in your app. The security implications of that are described in our documentation.