on 10-07-2004 7:14 AM
Hey there,
I hav a great Problem. I wrote a C# Program which runs as a Server. whithin this I wrote a Method i want to call from ABAP. This method needs to get two static and various dynamic parameters. In C# it is quite easy to implement this, by "params object[]...", but how can I get these Parameters from SAP to my Application?
When I describe the Parameter for RFC then it works, e.g. by "[RfcParameter("INSTID",RFCTYPE.RFCTYPE_STRING,30,30,0,RFCINOUT.IN)]". Does i have to give a certain RFCTYPE? When i do so, it works? Please give help, i need this very urgent.
Regards
Hello,
Although ABAP/RFC does not support the syntax of variable function arguments directly, you can achieve the similar effect by packing the variable parameters into a ABAP table. On the C# side, you need to move (or convert if required) the values contained in the table parameter to an object array before invoking your C# method with variable number of parameters.
Regards,
Guangwei Li
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Ok, thanks for the advice.
So, I don't have a chance to make a call function'XXX' destination p_dest with variable parameters, so that a C# Application gets it into the object[] Array?
But in the COM4ABAP this is implemented. If you call the function com_invoke you also have dynamic parameters...
Perhaps this would be a nice funcionality for .NET Connector 3.0
Regards
Hello,
Sorry, the answer remains NO.
In COM4ABAP, this feature is implemented only for the generic invoking function COM_INVOKE itself, but not for those functions/methods invoked through COM_INVOKE. So this functionality is perhaps "nice" to the developer who wrote COM4ABAP. But for the users of COM4ABAP, it seemed not to make much sense.
Of course, the support to dynamic parameters will be important if you want to write a generic method invoker for .NET (something might be called as DOTNET4ABAP). There is for now no plan to provide this feature in the future releases of the .NET Connector.
Regards,
Guangwei
User | Count |
---|---|
87 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.