Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

LOGIN TO SAP SYSTEM from Ms Excell

Hello All,

I have one requriment, I have to login SAP system through Excell.

For login to MS Excell,is it  requried to SAP LOGON pad should be insatalled in SYSTEM.

I am using Below code to login.

Sub logon_to_sap()

Set ObjR3 = CreateObject("SAP.Functions")

    '--get this info from your logon pad..

           ObjR3.Connection.System = "CRM" 'System name like : DEV 3 letter'

           ObjR3.Connection.Client = "100" 'client number like 100'

           ObjR3.Connection.User = ""   'User ID to logon '

           ObjR3.Connection.Password = ""  'Password '

           ObjR3.Connection.Language = "EN" 'Language'

           ObjR3.Connection.ApplicationServer = "xx.xx.xx.xx 'Applicaiotn server name e.g. 10.x.x.x'

           ObjR3.Connection.SystemNumber = "00" 'Instance number'

        

        '--if no logon then exit\

           If ObjR3.Connection.logon(0, False) <> True Then

              WScript.Echo "Sap connection error - " & ObjR3.Connection.User & " - " & ObjR3.Connection.System

              WScript.Quit

           End If

        

End Sub

But I am getting below Error.

Error Group

RFC_ERROR_COMMUNICATION

Message

CMALLC : rc=20 > Connect from SAP gateway to RFC
server failed

Connect_PM  GWHOST='XX.XX.XX.XX , GWSERV=sapgw00,
SYSNR=00

LOCATION    SAP-Gateway on host

ERROR       partner
'XX.XX.XX.XX sapgw00' not reached

TIME         Sep
10:21:50 2014

RELEASE     721

COMPONENT   NI (network interface)

VERSION     40

RC        
-10

MODULE      nixxi.cpp

LINE        3286

DETAIL      NiPConnect2:
SYSTEM CALL connect

ERRNO       10060

ERRNO TEXT  WSAETIME

Thanks In advance.

Regards

RR Pradhan

Tags:
Former Member
Not what you were looking for? View more on this topic or Ask a question