on 02-28-2005 1:41 PM
I have a console application that acts as an RFC server. When I start it, it connects to 4 r3 Applications servers. It works great and test fine from SM59.
The problem is when they take the R3 system down for an offline backup or other emergency, my console application loses its connections. Does anybody have any suggestions for how to have the console application check the connection programatically.
Appricatiate any ideas.
Regards,
Tom
Sorry, forgot to say that I am using the .net Connector for SAP.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Thomas,
Can you please tell me how did you implement your functions in your server program.
After adding SAP Connector Proxy then did you add any existing SAP function module (like RFC_CUSTOMER_GET as given in .NET connector help doc) or created your own .NET function which uses its own structure.
Can you please provide me with a sample code?
Stephen
To create an RFC server you allways need one ore more RFC function module(s) defined on an SAP server that declares the structure of your API. The implementation can be empty, but it has to exist.
After dragging the needed functions to the .sapwsdl designer, delete the <name>Impl.cs file, right-click the .sapwsdl file and select "Run Custom tool". Now fill your implementation into the Impl.cs file.
Like Rainer said, I did it. If you already need it, try this:
public class ServerHost : SAP.Connector.SAPServerHost
{
/// <summary>
/// Event OnServerException thrown after a Exception occured in the Server
/// </summary>
public event OnServerException ServerException;
/// <summary>
/// Method thrwos the Event OnServerException and writes a Message to Console Output
/// </summary>
/// <param name="server">object</param>
/// <param name="e">Event Arguments</param>
/// <returns>SAP.Connector.ActionOnServerException</returns>
public override ActionOnServerException OnServerException(SAP.Connector.SAPServer server, System.Exception e)
{
ServerException(this, System.EventArgs.Empty);
return ActionOnServerException.Reconnect;
}
}
I Hope this helps.
Regards
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
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.