Imports System
Imports System.Collections.Generic
Imports System.Data
Imports System.Data.Common
Imports System.Globalization
Imports System.IO
Imports System.Linq
Imports Microsoft.VisualBasic
Imports OneStream.Finance.Database
Imports OneStream.Finance.Engine
Imports OneStream.Shared.Common
Imports OneStream.Shared.Database
Imports OneStream.Shared.Engine
Imports OneStream.Shared.Wcf
Imports OneStream.Stage.Database
Imports OneStream.Stage.Engine
Namespace OneStream.BusinessRule.WcfEventHandler.WcfEventHandler
Public Class MainClass
Public Function Main(ByVal si As SessionInfo, ByVal globals As BRGlobals, ByVal api As Object, ByVal args As WcfEventHandlerArgs) As Object
Try
Dim returnValue As Object = args.DefaultReturnValue
args.UseReturnValueFromBusinessRule = False
args.Cancel = False
Select Case args.wcfServiceType
Case WcfServiceType.AdminGridServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'AdminGridServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.AnalyticsData
BRApi.ErrorLog.LogMessage(si,
"This event used the 'AnalyticsData' service. OperationName: " & args.OperationName)
Case WcfServiceType.ApplicationAdminServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'ApplicationAdminServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.Attachments
BRApi.ErrorLog.LogMessage(si,
"This event used the 'Attachments' service. OperationName: " & args.OperationName)
Case WcfServiceType.AttachmentsAjaxServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'AttachmentsAjaxServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.BusinessRuleServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'BusinessRuleServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.Calculate
BRApi.ErrorLog.LogMessage(si,
"This event used the 'Calculate' service. OperationName: " & args.OperationName)
Case WcfServiceType.ClientUpdaterServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'ClientUpdaterServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.CubeServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'CubeServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.CubeViews
BRApi.ErrorLog.LogMessage(si,
"This event used the 'CubeViews' service. OperationName: " & args.OperationName)
Case WcfServiceType.CubeViewsAjaxServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'CubeViewsAjaxServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.Dashboards
BRApi.ErrorLog.LogMessage(si,
"This event used the 'Dashboards' service. OperationName: " & args.OperationName)
Case WcfServiceType.DashboardsAjaxServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'DashboardsAjaxServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.Data
BRApi.ErrorLog.LogMessage(si,
"This event used the 'Data' service. OperationName: " & args.OperationName)
Case WcfServiceType.DataExplorerServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'DataExplorerServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.DataManagement
BRApi.ErrorLog.LogMessage(si,
"This event used the 'DataManagement' service. OperationName: " & args.OperationName)
Case WcfServiceType.DataManagementAjaxServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'DataManagementAjaxServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.DataProviderServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'DataProviderServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.DataQuality
BRApi.ErrorLog.LogMessage(si,
"This event used the 'DataQuality' service. OperationName: " & args.OperationName)
Case WcfServiceType.DataQualityAdminServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'DataQualityAdminServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.DataQualityProcessingServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'DataQualityProcessingServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.DimensionLibraryServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'DimensionLibraryServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.ExcelServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'ExcelServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.External
BRApi.ErrorLog.LogMessage(si,
"This event used the 'External' service. OperationName: " & args.OperationName)
Case WcfServiceType.FileExplorerServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'FileExplorerServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.Forms
BRApi.ErrorLog.LogMessage(si,
"This event used the 'Forms' service. OperationName: " & args.OperationName)
Case WcfServiceType.FormsAjaxServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'FormsAjaxServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.Framework
BRApi.ErrorLog.LogMessage(si,
"This event used the 'Framework' service. OperationName: " & args.OperationName)
Case WcfServiceType.FxRatesServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'FxRatesServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.Journals
BRApi.ErrorLog.LogMessage(si,
"This event used the 'Journals' service. OperationName: " & args.OperationName)
Case WcfServiceType.JournalsAjaxServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'JournalsAjaxServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.MemberSelectionServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'MemberSelectionServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.Metadata
BRApi.ErrorLog.LogMessage(si,
"This event used the 'Metadata' service. OperationName: " & args.OperationName)
Case WcfServiceType.MetadataAdmin
BRApi.ErrorLog.LogMessage(si,
"This event used the 'MetadataAdmin' service. OperationName: " & args.OperationName)
Case WcfServiceType.PovServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'PovServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.Security
BRApi.ErrorLog.LogMessage(si,
"This event used the 'Security' service. OperationName: " & args.OperationName)
Case WcfServiceType.SecurityAdminServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'SecurityAdminServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.SmartIntegrationManagementServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'SmartIntegrationManagementServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.StageAdminServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'StageAdminServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.StageData
BRApi.ErrorLog.LogMessage(si,
"This event used the 'StageData' service. OperationName: " & args.OperationName)
Case WcfServiceType.StageMetadata
BRApi.ErrorLog.LogMessage(si,
"This event used the 'StageMetadata' service. OperationName: " & args.OperationName)
Case WcfServiceType.StageProcessingServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'StageProcessingServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.SystemServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'SystemServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.TimeDimProfileServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'TimeDimProfileServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.Unknown
BRApi.ErrorLog.LogMessage(si,
"This event used the 'Unknown' service. OperationName: " & args.OperationName)
Case WcfServiceType.UserActivity
BRApi.ErrorLog.LogMessage(si,
"This event used the 'UserActivity' service. OperationName: " & args.OperationName)
Case WcfServiceType.UserActivityAjaxServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'UserActivityAjaxServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.Workflow
BRApi.ErrorLog.LogMessage(si,
"This event used the 'Workflow' service. OperationName: " & args.OperationName)
Case WcfServiceType.WorkflowAdminServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'WorkflowAdminServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.WorkflowAjaxServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'WorkflowAjaxServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.WsAssemblies
BRApi.ErrorLog.LogMessage(si,
"This event used the 'WsAssemblies' service. OperationName: " & args.OperationName)
Case WcfServiceType.WsAssembliesAjaxServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'WsAssembliesAjaxServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.Xbrl
BRApi.ErrorLog.LogMessage(si,
"This event used the 'Xbrl' service. OperationName: " & args.OperationName)
Case WcfServiceType.XbrlAjaxServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'XbrlAjaxServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.XFEnvironment
BRApi.ErrorLog.LogMessage(si,
"This event used the 'XFEnvironment' service. OperationName: " & args.OperationName)
Case WcfServiceType.XFEnvironmentAjaxServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'XFEnvironmentAjaxServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.XFFileSystem
BRApi.ErrorLog.LogMessage(si,
"This event used the 'XFFileSystem' service. OperationName: " & args.OperationName)
Case WcfServiceType.XFSmartIntegration
BRApi.ErrorLog.LogMessage(si,
"This event used the 'XFSmartIntegration' service. OperationName: " & args.OperationName)
Case WcfServiceType.XFSpreadsheet
BRApi.ErrorLog.LogMessage(si,
"This event used the 'XFSpreadsheet' service. OperationName: " & args.OperationName)
Case WcfServiceType.XFSql
BRApi.ErrorLog.LogMessage(si,
"This event used the 'XFSql' service. OperationName: " & args.OperationName)
Case WcfServiceType.XFSqlAjaxServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'XFSqlAjaxServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.XmlLoadExtractServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'XmlLoadExtractServiceFacade' service. OperationName: " & args.OperationName)
Case WcfServiceType.XtraReportViewer
BRApi.ErrorLog.LogMessage(si,
"This event used the 'XtraReportViewer' service. OperationName: " & args.OperationName)
Case WcfServiceType.XtraReportViewerAjaxServiceFacade
BRApi.ErrorLog.LogMessage(si,
"This event used the 'XtraReportViewerAjaxServiceFacade' service. OperationName: " & args.OperationName)
Case Else
' Fallback for service types not explicitly handled
BRApi.ErrorLog.LogMessage(si,
"This event used an unrecognized service type: " &
args.wcfServiceType.ToString() &
". OperationName: " & args.OperationName)
End Select
Return returnValue
Catch ex As Exception
Throw ErrorHandler.LogWrite(si, New XFException(si, ex))
End Try
End Function
End Class
End Namespace
Hi Celvin,
I hope you're doing well!
I'm trying to understand which event operation is triggered when the Submit Sheet action is executed in OneStream. To figure this out, I created a rule to identify the operation being triggered. However, none of the operations returned any results except for the Data operation during the SetDataCell operation, which isn’t the result I was looking for.
Could you please help me with this?
Thank you in advance for your support!
Best regards,
Omkareshwar