Announcement:
wanna exchange links? contact me at sapchatroom@gmail.com.
Posted by
Admin at
Reply from horacio zapettini on Aug 17 at 2:10 PM Wes, there's been a first time for all of us ;) (when I started, there was a couple of pages referencing this FM and excel). According to what we can read, Mauro has a good level of experience with VB. This FM is so used as an example that in http://visualbasic.ittoolbox.com/groups/technical-functional/visualbasic-l/rfc_read_table-543014 there is a thread that invokes it. As said in another thread, We've given Mauro the hook, line, fishing instructions and helped him in catching the first fishes. Now it's time for him to try to catch a fish by his own.
| | | ---------------Original Message--------------- From: Wes Arey Sent: Friday, August 17, 2012 1:52 PM Subject: SAP RFC Call Returns Error in Return Parameter from Vb Before the RFC Call Here is a sample from something I had around. You will need to adapt it to your own needs. The input table "options" contains the where clause. The input table "fields" contains the field list of values to return from the query You can add to input tables using Appendrow Dim codes2 = bapi.Add("RFC_READ_TABLE") codes2.exports("QUERY_TABLE") = "MSEG" codes2.exports("DELIMITER") = "|" Dim Opts As Object = codes2.Tables("OPTIONS") Opts.Appendrow() Opts(1, "TEXT") = "MJAHR EQ 2011 AND AUFNR EQ '001000375125'" Dim fld As Object = codes2.tables("FIELDS") fld.appendrow() fld(1, "FIELDNAME") = "MBLNR" fld.appendrow() fld(2, "FIELDNAME") = "RSNUM" codes2.call() Dim tab As Table tab = codes2.Tables("DATA") returnedRows = tab.RowCount aValue = tab.cell(x,y) Be careful if you loop on this as the input tables stay populated between calls use .freetable() to remove the rows Horacio - Yeah he can look online but if you've never done it before the syntax is obtuse. Wes | | Reply to this email to post your response. __.____._ | _.____.__ |