So I have a custom action
<CustomAction Id="GetTarget"
BinaryKey="CA"
DllEntry="GetTargetPath"
Execute="immediate"
Return="check"
HideTarget="no"
Impersonate="no" />
<InstallExecuteSequence>
<Custom Action="GetTarget" After="CostFinalize">(NOT REMOVE = "ALL")</Custom>
</InstallExecuteSequence>
This is calling a DLL that calls the method session.GetTargetPath("TARGETPATH");
But I get an exception "The directory name is invalid. TARGETPATH". I have the custom action as After="CostFinalize"
as this is what I read from a source (which I can provide) but I think there is a mistake and I think that I just have to to execute the action at the right time.