Ejemplo n.º 1
0
        /// <summary>
        /// 함수의 인자 정보를 반환한다. SAP 서버에 연결되지 않은 경우, null 값을 반환.
        /// </summary>
        /// <param name="strFuncName">함수 이름</param>
        /// <param name="strLang">언어</param>
        /// <returns>SAP 함수의 인자 정보 (ADO.NET DataTable)</returns>
        private DataTable RFC_Get_Function_Interface(string strFuncName, string strLang)
        {
            RFC_FUNINTTable oRFCFT = null; // RFC_FUNINT 클래스

            // SAP 서버에 연결되지 않은 경우, null 값을 반환하고 함수를 종료한다.
            if (this.Connection.IsOpen == false)
            {
                return(null);
            }

            try
            {
                oRFCFT = new RFC_FUNINTTable();

                // none_unicode_length => 공백과 'X'를 사용
                // 공백일 경우엔 unicode 길이를, 'X'일 경우엔 non-unicode 파라미터 길이를 반환함.
                RFC_GET_FUNCTION_INTERFACE(strFuncName, strLang, "X", ref oRFCFT);
            }
            catch (Exception exp)
            {
                throw exp;
            }

            return(oRFCFT.ToADODataTable()); // Converts the SAP table to an ADO.NET DataTable.
        }
Ejemplo n.º 2
0
        public virtual void RFC_GET_FUNCTION_INTERFACE(

            [RfcParameter(AbapName = "FUNCNAME", RfcType = RFCTYPE.RFCTYPE_CHAR, Optional = false, Direction = RFCINOUT.IN, Length = 30, Length2 = 60)]
            [XmlElement("FUNCNAME", IsNullable = false, Form = XmlSchemaForm.Unqualified)]
            string FUNCNAME,
            [RfcParameter(AbapName = "LANGUAGE", RfcType = RFCTYPE.RFCTYPE_CHAR, Optional = true, Direction = RFCINOUT.IN, Length = 1, Length2 = 2)]
            [XmlElement("LANGUAGE", IsNullable = false, Form = XmlSchemaForm.Unqualified)]
            string LANGUAGE,
            [RfcParameter(AbapName = "NONE_UNICODE_LENGTH", RfcType = RFCTYPE.RFCTYPE_CHAR, Optional = true, Direction = RFCINOUT.IN, Length = 1, Length2 = 2)]
            [XmlElement("NONE_UNICODE_LENGTH", IsNullable = false, Form = XmlSchemaForm.Unqualified)]
            string NONE_UNICODE_LENGTH,
            [RfcParameter(AbapName = "PARAMS", RfcType = RFCTYPE.RFCTYPE_ITAB, Optional = false, Direction = RFCINOUT.INOUT)]
            [XmlArray("PARAMS", IsNullable = false, Form = XmlSchemaForm.Unqualified)]
            [XmlArrayItem("item", IsNullable = false, Form = XmlSchemaForm.Unqualified)]
            ref RFC_FUNINTTable PARAMS)
        {
            object[] results = null;
            results = this.SAPInvoke("RFC_GET_FUNCTION_INTERFACE", new object[] { FUNCNAME, LANGUAGE, NONE_UNICODE_LENGTH, PARAMS });
            PARAMS  = (RFC_FUNINTTable)results[0];
        }
Ejemplo n.º 3
0
        private DataTable RFC_Get_Function_Interface(string strFuncName, string strLang)
        {
            RFC_FUNINTTable oRFCFT = null;

            if (this.Connection.IsOpen == false)
            {
                return(null);
            }

            try
            {
                oRFCFT = new RFC_FUNINTTable();
                RFC_GET_FUNCTION_INTERFACE(strFuncName, strLang, "X", ref oRFCFT);
            }
            catch (Exception exp)
            {
                throw exp;
            }

            return(oRFCFT.ToADODataTable()); // Converts the SAP table to an ADO.NET DataTable.
        }