Extract Metadata from HFM
852598May 14 2011 — edited May 16 2011Goodmorning,
I'm looking for HFM API that could be used by FDM Event Script to extract Account Type (metadata, more generally). Precisely:
When I'm importing source account, I've to verify that target account has a specified type, cause I've to change sign manually (sob), but I'm not pretty sure where put this behaviour (I think BefValidate or After Mapping) and how can I determine target account. I've found something like:
---
Function isCurrencyRateType(sMem As String) As Boolean Dim cAccounts As HsvAccounts, cTreeInfo As IHsvTreeInfo Dim lAccount As Long, iAcctType As Integer 'g_cMetadata is an HsvMetadata object reference
Set cAccounts = g_cMetadata.Accounts Set cTreeInfo = g_cMetadata.Accounts lAccount = cTreeInfo.GetItemID(sMem) cAccounts.GetAccountType lAccount, iAcctType If iAcctType = ACCOUNTTYPE_CURRENCYRATE Then
isCurrencyRateType = True Else
isCurrencyRateType = False End If
End Function
---
on HFM Object Guide, is it the right way?
Thanks
Francesco