hi friends,
i create this piece of code and it is running ok as a .vbs script. the problem is only the last line of code. It is saying that the method is not supported, how can i fixed this problem ?..now the code:
the message: "the object does not support setcelldata method"... it seems that the operations are different than in qtp..
i create this piece of code and it is running ok as a .vbs script. the problem is only the last line of code. It is saying that the method is not supported, how can i fixed this problem ?..now the code:
Code:
set WshShell = CreateObject("WScript.Shell")
Set proc = WshShell.Exec("C:\Archivos de Programa\SAP\FrontEnd\SAPgui\saplogon.exe")
Do While proc.Status = 0
WScript.Sleep 500
Loop
Set SapGui = GetObject("SAPGUI")
Set Appl = SapGui.GetScriptingEngine
Set Connection = Appl.Openconnection("BST - Integracion", True)
Set session = Connection.Children(0)
session.findById("wnd[0]/usr/txtRSYST-BNAME").Text = "l0609285"
session.findById("wnd[0]/usr/pwdRSYST-BCODE").Text = "dm5srH5c"
session.findById("wnd[0]/usr/txtRSYST-LANGU").Text = "ES"
session.findById("wnd[0]").sendVKey 0
session.findById("wnd[0]/tbar[0]/okcd").Text = "/n/BGBA/LM_LOAN_01"
session.findById("wnd[0]").sendVKey 0
session.findById("wnd[0]/usr/ctxtGV_TIPO_DOC").Text = "CUIL"
session.findById("wnd[0]/usr/txtGV_NRO_DOC").Text = "30515838399"
session.findById("wnd[0]/usr/btnLC_BUSCAR").press
Do While proc.Status = 0
WScript.Sleep 100
Loop
session.findById("wnd[0]/usr/ctxtCN_BEGIN_D").Text = "20.11.2008"
session.findById("wnd[0]/usr/ctxtGV_DATA-VTA_ORGUNIT").Text = "0063"
session.findById("wnd[0]/usr/ctxtGV_DATA-PROD_COM").Text = "SF_FIJOFUL"
session.findById("wnd[0]/usr/ctxtGV_DATA-INST_ORGUNIT").Text = "0063"
session.findById("wnd[0]/usr/btnLC_SAVE").press
Do While proc.Status = 0
WScript.Sleep 100
Loop
session.findById("wnd[0]/usr/tabsFICHA/tabpFICHA_FC1/ssubFICHA_SCA:/BGBA/SAPMLM_LOAN_CREATE:0201/ctxtGV_DATA-DESTINO").Text = "CAP"
session.findById("wnd[0]/usr/tabsFICHA/tabpFICHA_FC1/ssubFICHA_SCA:/BGBA/SAPMLM_LOAN_CREATE:0201/ctxtGV_DATA-COND_GAR").Text = "PAG"
session.findById("wnd[0]/usr/tabsFICHA/tabpFICHA_FC1/ssubFICHA_SCA:/BGBA/SAPMLM_LOAN_CREATE:0201/ctxtGV_DATA-DOC_LEG_GAR").Text = "PAGARE"
session.findById("wnd[0]").sendVKey 0
session.findById("wnd[0]/usr/tabsFICHA/tabpFICHA_FC3").select
session.findById("wnd[0]/usr/tabsFICHA/tabpFICHA_FC3/ssubFICHA_SCA:/BGBA/SAPMLM_LOAN_CREATE:0203/cmbGV_DATA-FIN_COND-AC_CONTRACT-DIVISOR").key = "365"
set session.findById("wnd[0]/usr/tabsFICHA/tabpFICHA_FC3/ssubFICHA_SCA:/BGBA/SAPMLM_LOAN_CREATE:0203/tbl/BGBA/SAPMLM_LOAN_CREATETASAS").SetCellData 1, "Tasa","14"
the message: "the object does not support setcelldata method"... it seems that the operations are different than in qtp..