XFBR for Column Set

DCarrillo
New Contributor III

Hi all,

 

I'm trying to give the end-user the option to enter their forecasts in either 13 week increments (a quarter essentially) or for the full 52 weeks. This specific XFBR will determine the green cells below.

 

DGC_0-1667954106344.png

DGC_1-1667954690756.png

I'm unsure of what line 28 should be or if this XFBR could be easier to define. Week13Column and FullYearColumn are existing parameters that list 13 weeks of scenario and the full 52 weeks of scenario, respectively.

 

Thanks!

3 REPLIES 3

Michel_Sabourin
Contributor II

After Dim columnname, I would create a result string, like Dim Result as String = Nothing. Then you can define the answer in your If statement. 

If columnname, etc Then

Result = "S#Week01:S#Week13"

else

result = "S#Weekly.Base"

End if

Return Result

 

I edited my XFBR but I only get the full 52 weeks automatically, not the option of either 13 weeks or the full 52 week view column set up. Does the 'Dim Result as String = Nothing' portion of the XFBR give me back the 0.00 in the second pic?

DGC_0-1668019484673.png

Data Explorer Output all the way to Week52:

DGC_3-1668019634270.png

 

 

 

The Dim Result as String = Nothing just allows the rule to compile with no warning messages. Before the If coulmnname section, add brapi.ErrorLog.LogMessage(si,"ColumnName = " & columnname). after you try the Cube View again, go to the Error Log and see if it's returning the expected column name. If that looks good, try adding a log message right before Return Result and see what the system is passing back to the XFBR