SAP interface programming with RFC and VBA
eBook - ePub

SAP interface programming with RFC and VBA

Edit SAP data with MS Access

Karl Josef Hensel

  1. English
  2. ePUB (mobile friendly)
  3. Available on iOS & Android
eBook - ePub

SAP interface programming with RFC and VBA

Edit SAP data with MS Access

Karl Josef Hensel

Book details
Book preview
Table of contents
Citations

About This Book

The migration of data is an important process when introducing SAP systems or adopting new data from third-party systems. This takes up a large proportion of the time and thus also the costs in migration projects. This book gives you practical tips and examples of how you can use Microsoft products and the VBA programming language to quickly and inexpensively create useful migration tools yourself. It is not necessary to install the software on the SAP systems. This saves the time-consuming procedure of software implementation in SAP systems. Developments with ABAP code, complex documentation, tests in development, quality and productive systems are not necessary and save time and money. The batch input interface and the LSMW and CATT tools are no longer required.The book is suitable for administrators, technical consultants and developers in the SAP environment. Even power users from the specialist departments will be able to produc-tively extract or upload data from the SAP systems after reading it. The programs created according to my method can be used for all SAP modules. As an example, I use functionalities of the SAP module PS. By using ready-made SAP functions and BAPI's, functionalities such as creating and changing projects and WBS-Elements can be carried out.

Frequently asked questions

How do I cancel my subscription?
Simply head over to the account section in settings and click on “Cancel Subscription” - it’s as simple as that. After you cancel, your membership will stay active for the remainder of the time you’ve paid for. Learn more here.
Can/how do I download books?
At the moment all of our mobile-responsive ePub books are available to download via the app. Most of our PDFs are also available to download and we're working on making the final remaining ones downloadable now. Learn more here.
What is the difference between the pricing plans?
Both plans give you full access to the library and all of Perlego’s features. The only differences are the price and subscription period: With the annual plan you’ll save around 30% compared to 12 months on the monthly plan.
What is Perlego?
We are an online textbook subscription service, where you can get access to an entire online library for less than the price of a single book per month. With over 1 million books across 1000+ topics, we’ve got you covered! Learn more here.
Do you support text-to-speech?
Look out for the read-aloud symbol on your next book to see if you can listen to it. The read-aloud tool reads text aloud for you, highlighting the text as it is being read. You can pause it, speed it up and slow it down. Learn more here.
Is SAP interface programming with RFC and VBA an online PDF/ePUB?
Yes, you can access SAP interface programming with RFC and VBA by Karl Josef Hensel in PDF and/or ePUB format, as well as other popular books in Informatique & Applications de bureau. We have over one million books available in our catalogue for you to explore.

Information

Publisher
tredition
Year
2022
ISBN
9783347574793
Chapter 1
Chapter 1.1 – The logon to the SAP system
You have to decide on a login type in advance when programming.
I definitely recommend using the logon for functions and staying on track.
Set FunctionCtrl = CreateObject("SAP.Functions")
The advantage is that all SAP functions as well as all BAPI functions can be used, which is not possible the other way around and leads to a constant new logon.
If no logon parameters are given in the program, the SAP GUI logon is used automatically.
Logon example:
'******** RFC LOGON ****************
If Not sapConnection Is Nothing Then
If sapConnection.IsConnected <> 1 Then
If RFC_Connect() = False Then Exit Sub
End If
Else
If RFC_Connect() = False Then Exit Sub
End If
'******** RFC LOGON END ************
Requirements:
Create a module in which all RFC functions are collected, e.g.
Module name SAP_RFC
The following objects are declared:
Declarations:
Public FunctionCtrl As Object
Public sapConnection As Object
Private oRowOPTIONS As Object
Private Akt_User As String
Private Akt_PW As String
Private Akt_SAP_System As String
Private Akt_SAPMandant As String
Private Akt_SAPLang As String
Private Akt_ApplicationServer As String
Private Akt_SystemNumber As Integer
Private oRFC_READ_TABLE As Object
Private MyArray(10) As Variant
Required functions:
' *********************************************************************************
' Public Functions
' *********************************************************************************
Public Function RFC_Connect(Optional s_User = "", _
Optional s_PW = "", _
Optional s_SAP_System = "", _
Optional s_SAPMandant = "", _
Optional s_SAPLang = "", _
Optional s_ApplicationServer = "", _
Optional i_SystemNumber = 0) As Boolean
On Error GoTo Error
Dim Pruefnummer
Dim TEMP As Variant
RFC_Connect = False
' Parameter setzen
If s_User <> "" Then Akt_User = s_User
1:
Pruefnummer = 1
TEMP = FunctionCtrl.Count
2:
Pruefnummer = 2
If sapConnection.IsConnected <> 1 Then GoTo Error
RFC_Connect = True
Exit Function
Error:
Err.Clear
Select Case Pruefnummer
Case 1 ' FunctionCtrl nicht initiert.
pr_Init
GoTo 1
Case 2 ' Noch keine SAP-Anmeldung
If pr_Logon() = False Then Exit Function
GoTo 2
End Select
End Function
' *********************************************************************************
' Private Functions
' *********************************************************************************
Private Sub pr_Init()
Set FunctionCtrl = CreateObject("SAP.Functions")
Set sapConnection = FunctionCtrl.Connection
End Sub
Private Function pr_Logon() As Boolean
Dim silent As Boolean
If sapConnection.IsConnected = 1 Then Exit Function
sapConnection.Client = Akt_SAPMandant
sapConnection.LANGUAGE = Akt_SAPLang
sa...

Table of contents

  1. Cover
  2. Title Page
  3. Table of Contents
  4. Chapter 1
  5. Chapter 2
  6. Chapter 3
  7. Chapter 4
  8. Chapter 5
  9. Chapter 6
  10. Chapter 7
  11. Epilogue:
  12. Index
  13. Copyright
Citation styles for SAP interface programming with RFC and VBA

APA 6 Citation

Hensel, K. J. (2022). SAP interface programming with RFC and VBA (1st ed.). tredition. Retrieved from https://www.perlego.com/book/3282747/sap-interface-programming-with-rfc-and-vba-edit-sap-data-with-ms-access-pdf (Original work published 2022)

Chicago Citation

Hensel, Karl Josef. (2022) 2022. SAP Interface Programming with RFC and VBA. 1st ed. tredition. https://www.perlego.com/book/3282747/sap-interface-programming-with-rfc-and-vba-edit-sap-data-with-ms-access-pdf.

Harvard Citation

Hensel, K. J. (2022) SAP interface programming with RFC and VBA. 1st edn. tredition. Available at: https://www.perlego.com/book/3282747/sap-interface-programming-with-rfc-and-vba-edit-sap-data-with-ms-access-pdf (Accessed: 15 October 2022).

MLA 7 Citation

Hensel, Karl Josef. SAP Interface Programming with RFC and VBA. 1st ed. tredition, 2022. Web. 15 Oct. 2022.