Welcome Notes

Welcome Viewers

02 March 2018

Open Form through Menu ID SAP B1 SDK

Dear All,
   Today , We will see, How to Open Form through Menu ID SAP B1 SDK.


 Public Sub OpenFormThroughMenuId(ByVal SBO_Application As SAPbouiCOM.Application, ByVal oActMenu As String)
        SBO_Application.ActivateMenuItem(oActMenu)
    End Sub

Bind Current Date through SDK

Dear All,
   Today , We will see, How to Bind Current Date in Edit Text through SDK



Public Sub BindDate(ByVal oForm As SAPbouiCOM.Form, ByVal oDsName As Object, ByVal dbAlias As Object)

        Dim oDBDataSource As SAPbouiCOM.DBDataSource = Nothing
        oDBDataSource = oForm.DataSources.DBDataSources.Item(oDsName)
        Try
            With oDBDataSource
                .SetValue(dbAlias, 0, DateTime.Today.ToString("yyyyMMdd"))
            End With
        Catch ex As Exception
        End Try
    End Sub

Assign CFL To EditText through SDK

Dear All,
   Today , We will see, How to Assign CFL To EditText through SDK



 Public Sub AssignCFLToEditText(ByVal aForm As SAPbouiCOM.Form, ByVal strEditUid As String, ByVal strCFLId As String, ByVal strCFLAliase As String)
        Dim oItem As SAPbouiCOM.Item = Nothing
        Dim oEdit As SAPbouiCOM.EditText = Nothing
        Try
            oItem = aForm.Items.Item(strEditUid)
            oEdit = oItem.Specific
            oEdit.ChooseFromListUID = strCFLId
            oEdit.ChooseFromListAlias = strCFLAliase
        Catch ex As Exception

        Finally
            If oItem IsNot Nothing Then
                oItem = Nothing
            End If
            If oEdit IsNot Nothing Then
                oEdit = Nothing
            End If
        End Try


    End Sub

Get Current User Signature through SDK

Dear All,
   Today , We will see, How to Get Current User Signature through SDK



oApplication.SAPCompany.UserSignature

Get Current User Name through SDK

Dear All,
   Today , We will see, How to Get Current User Name through SDK



oApplication.SAPCompany.UserName.Trim

Set Cell BackColor and ForeColor through SAP B1 SDK

Dear All,
   Today , We will see, How to set CellB Back Color and ForeColor through SDK.



Imports System.Drawings

oGrid.Column.Item("ColName").Backcolor = ColorTranslator.ToOle(Color.White)