on 04-18-2012 12:26 AM
Hello,
I am using the NCo 3.0 with VS2010 and .Net 4. I am able to make RFC calls using the following code:
var par = new RfcConfigParameters();
//config par here
....
var dest = RfcDestinationManager.GetDestination(par);
This works fine, and I am able to successfully call my BAPI, and get the date from the resulting table.
--------------
But when I try to configure the destination in my in the App.config file, like this:
<configSections>
<sectionGroup name="SAP.Middleware.Connector">
<sectionGroup name="ClientSettings">
<section name="DestinationConfiguration" type="SAP.Middleware.Connector.RfcDestinationConfiguration, sapnco"/>
</sectionGroup>
</sectionGroup>
</configSections>
<SAP.Middleware.Connector>
<ClientSettings>
<DestinationConfiguration>
<destinations>
<add NAME="mysrvr"
USER="sdf" PASSWD="sdf"
AHOST="sap-xpa-01" CLIENT="100" SYSNR="00"
MAX_POOL_SIZE="10" IDLE_TIMEOUT="10" LANG="EN"
/>
</destinations>
</DestinationConfiguration>
</ClientSettings>
</SAP.Middleware.Connector>
The instantiate the destination like this:
RfcDestinationManager.GetDestination("mysrvr"); //throws exception
This code throws an exception, saying that mysrvr can not be found.
I have have tried using the 'App.config' of a Unit Test project, as well as the 'app.config' of a Console Application. What am I doing wrong here?
I was also facing the similar issue.. However I found that it works with only one destination in config file. It does not supports the multiple destinations.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello,
I am experiencing the same problem. Were you able to solve the issue?
Best regards
Sebastian Dorsch
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
80 | |
9 | |
9 | |
7 | |
7 | |
6 | |
6 | |
6 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.