‎2013 Oct 30 9:44 AM
Hello Expert,
I am tring to do an HTTP post, using the method 'cl_gui_frontend_services=>execute'.
However, I am not able to do so, when I am trying to do a get using the same method, it works fine.
I am sure there would be multiple posts on the forum regarding the issue but I am not able to find anything relevant.
If you could provide a solution or any post which is similar, it would be great.
Thanks in advance.
‎2013 Oct 30 1:32 PM
‎2013 Oct 31 7:29 AM
I am not getting eny error.
The below GET method is working fine:
data: l_url_doculink type string.
l_url_doculink = 'http://198.101.151.32/ReadHttp/Getparameters.aspx?userPassword=vikesh'.
CALL METHOD cl_gui_frontend_services=>execute
EXPORTING
document = l_url_doculink
EXCEPTIONS
OTHERS = 1.
if sy-subrc = 0.
write: 'url opened'.
else.
write:'method call failed with sy-subrc'.
endif.
----------------------------------------------------------------------------------------------------------------------------------
HOwever when I am trying to POST using below code it is not working
data: l_url_doculink type string.
data: parameter_url type string.
l_url_doculink = 'http://198.101.151.32/Readhttp/PostParameter.aspx'.
parameter_url =
'userPassword=vikesh*123&userName=vikesh&subUserId=vksh1&jobId=1001&secretKey=aC4adsTYgqipm&successPageUrlRedirect=http://198.101.151.32/Readhttp/PostParameter.aspx&failurePageUrlRedirect=http://localhost:64934/Read...'.
CALL METHOD cl_gui_frontend_services=>execute
EXPORTING
document = l_url_doculink
parameter = parameter_url
EXCEPTIONS
OTHERS = 1.
if sy-subrc = 0.
write: 'url opened'.
else.
write:'method call failed with sy-subrc'.
endif.
Kindly help.