Forum Discussion
MarcusH
5 hours agoValued Contributor
I think the problem is the Origin member for the destination. Change that to Forms. Also I would not specify a specific currency on the Consolidation member unless you are transferring translated values. Either set it to C#Local or leave it out completely. If you still want to debug I would use a data buffer to get the before and after data something like this:
Dim listAccounts As New List(Of String) From {"3PFB_Capital", "3PFB_Expense", "Travel_Capital", "Travel_Expense" }
Dim debugNumberLines as integer = 100
For Each thisAcc As String In listAccounts
Dim srcDataBuffer As DataBuffer = api.Data.GetDataBufferUsingFormula($"RemoveZeros(S#Rpt_Feb:A#{thisAcc}:" & sourceDims & ")", , False)
srcDataBuffer.LogDataBuffer(api, $"Source data for account [{thisAcc}]", debugNumberLines)
Next
'Seed Current Scenario with previous imported 3rd party data
api.Data.Calculate("S#" & curScenarioName & ":A#3PFB_Capital:" & destinationDims & " = RemoveZeros(S#Rpt_Feb:A#3PFB_Capital:" & sourceDims & ")",True)
api.Data.Calculate("S#" & curScenarioName & ":A#3PFB_Expense:" & destinationDims & " = RemoveZeros(S#Rpt_Feb:A#3PFB_Expense:" & sourceDims & ")",True)
api.Data.Calculate("S#" & curScenarioName & ":A#Travel_Capital:" & destinationDims & " = RemoveZeros(S#Rpt_Feb:A#Travel_Capital:" & sourceDims & ")",True)
api.Data.Calculate("S#" & curScenarioName & ":A#Travel_Expense:" & destinationDims & " = RemoveZeros(S#Rpt_Feb:A#Travel_Expense:" & sourceDims & ")",True)
For Each thisAcc As String In listAccounts
Dim tgtDataBuffer As DataBuffer = api.Data.GetDataBufferUsingFormula($"RemoveZeros(S#{curScenarioName}:A#{thisAcc}:" & destinationDims & ")", , False)
tgtDataBuffer.LogDataBuffer(api, $"Calculated data for account [{thisAcc}]", debugNumberLines)
Next
Related Content
- 26 days ago
- 3 years ago
- 4 years ago
- 1 year ago