If you created the ident in a C++ task, just copy the ident (which is the .ident output of the FB ArEventLogCreate, it’s an UDINT) on a global PLC variable, and use it for function block calls in the AB task.
The 2nd possibility is to call the function block ArEventLogGetIdent in the AB task.
This function block determines the ident by the given logger module name (which is a string).
Then, there’s no need to share the ident out of the C++ program.
Best regards!