cancel
Showing results for 
Search instead for 
Did you mean: 

/SOMO/GET_TIMEZONE rfc invocation issue

Former Member
0 Kudos
162

Hi Reiner,

I have an issue with invoking the rfc '/SOMO/GET_TIMEZONE'.

this works fine using se37.

When i build the proxy client.

1> the wsdl description defines a method Somo_Get_Timezone

2> the proxy class [.cs] does not create the method to implement the rfc.

3> i created a method myself, but upon

invocation

results = this.SAPInvoke("Somo_Get_Timezone",new object[] {});

error msg :"invalid method Somo_Get_Timezone."

-


or -


results = this.SAPInvoke("/SOMO/GET_TIMEZONE",new object[] {});

error msg :"invalid method/SOMO/GET_TIMEZONE."

any combination yields similar results...

any thoghts ?

Thanks,

Amit.

View Entire Topic
reiner_hille-doering
Active Contributor
0 Kudos

We had a problem with "namespaced" functions in the very early version of NCo (1.0.0). With the current 2.0.1 I cannot repro any problem. It correctly create a proxy like this:

/// <summary>

/// Remote Function Module /SOMO/GET_TIMEZONE.

/// To get the timezone, date and time from this system for solution manager

/// </summary>

/// <param name="Date"></param>

/// <param name="Time"></param>

/// <param name="Tzone"></param>

[RfcMethod(AbapName = "/SOMO/GET_TIMEZONE")]

[SoapDocumentMethodAttribute("http://tempuri.org/_-SOMO_-GET_TIMEZONE",

RequestNamespace = "urn:sap-com:document:sap:rfc:functions",

RequestElementName = "_-SOMO_-GET_TIMEZONE",

ResponseNamespace = "urn:sap-com:document:sap:rfc:functions",

ResponseElementName = "_-SOMO_-GET_TIMEZONE.Response")]

public virtual void Somo_Get_Timezone (

[RfcParameter(AbapName = "DATE",RfcType=RFCTYPE.RFCTYPE_DATE, Optional = true, Direction = RFCINOUT.OUT, Length = 8, Length2 = 16)]

[XmlElement("DATE", IsNullable=false, Form=XmlSchemaForm.Unqualified)]

out string Date,

[RfcParameter(AbapName = "TIME",RfcType=RFCTYPE.RFCTYPE_TIME, Optional = true, Direction = RFCINOUT.OUT, Length = 6, Length2 = 12)]

[XmlElement("TIME", IsNullable=false, Form=XmlSchemaForm.Unqualified)]

out string Time,

[RfcParameter(AbapName = "TZONE",RfcType=RFCTYPE.RFCTYPE_INT, Optional = true, Direction = RFCINOUT.OUT, Length = 4, Length2 = 4)]

[XmlElement("TZONE", IsNullable=false, Form=XmlSchemaForm.Unqualified)]

out int Tzone)

{

object[]results = null;

results = this.SAPInvoke("Somo_Get_Timezone",new object[] {

});

Date = (string) results[0];

Time = (string) results[1];

Tzone = (int) results[2];

}