I try to get data from the CustomActionData property in a c++ dll, but it's always empty during the deferred sequence. If I use the exact same code in a CA executed during the UI sequence it all works great.
UINT iCASize = 0;
UINT uiStat = MsiGetProperty(hInstall, TEXT("CustomActionData"), TEXT(""), &iCASize);
if (uiStat == ERROR_MORE_DATA)
{
// this means there are data to read. Allocate array for all data and read it (+1 for null termination)
pCustData = new WCHAR[iCASize + 1];
uiStat = MsiGetProperty(hInstall, TEXT("CustomActionData"), pCustData, &iCASize);
}
Any of you out there have an idea what could be wrong?