I have recorded an script which makes the Save As dialog pops up, in transaction code FBL5N
.
However I cannot use any command such as sendkey
.
I need a code to provide a file path and file name.
so far I have the below code: (coming from SAP script recording and playback)
If Not IsObject(application) Then
Set SapGuiAuto = GetObject("SAPGUI")
Set application = SapGuiAuto.GetScriptingEngine
End If
If Not IsObject(connection) Then
Set connection = application.Children(0)
End If
If Not IsObject(session) Then
Set session = connection.Children(0)
End If
If IsObject(WScript) Then
WScript.ConnectObject session, "on"
WScript.ConnectObject application, "on"
End If
session.findById("wnd[0]").maximize
session.findById("wnd[0]/usr/lbl[30,2]").setFocus
session.findById("wnd[0]/usr/lbl[30,2]").caretPosition = 25
session.findById("wnd[0]").sendVKey 16
Thank you.
David