cancel
Showing results for 
Search instead for 
Did you mean: 

IP address of client of webdynpro application

Former Member
0 Kudos

Hello,

is it possible to determine IP address of client from webdynpro application?

Thanks in advance.

Zdenek Smolik.

Accepted Solutions (0)

Answers (3)

Answers (3)

former_member413959
Participant
0 Kudos

Hi,

is it possible to determine IP address of client from WebDynpro application in 7 version?

IWebContextAdapter is invalid in 7 version .

Thanks.

Former Member
0 Kudos

Hi Pran,

thank you, I'll try it.

Regards,

Zdenek

Former Member
0 Kudos

And you know that you make your Web Dynpro application "invalid" by using a non-API method...

Former Member
0 Kudos

Hello ,

I developed servlet which retrieves IP address from request and renders html page which redirect to webdynpro application and using GET method pass the IP address as parameter.

But exists some "legal" way how to do it using webdynpro API?

Regards Zdenek.

Former Member
0 Kudos

Legal way...Nah I dont think SAP will throw in a law suit if you use the above api )

But I guess Armin should know some other way

Regards

Pran

Former Member
0 Kudos

Don't let me get misunderstood. I did not say "legal" or something like that.

I just wanted to point out that using non-API methods is not supported and your application may break some "day".

Armin

StefanBeck
Advisor
Advisor
0 Kudos

Hi Zdenek Smolik,

to clarify the statements above. The next release is already in development and that API call mentioned above will definitely no longer work. That means your application stops working with...

Can you please tell me the reason for working with client IP? Maybe there is a different solution or we have to think about offering a public API.

Regards

Stefan

Former Member
0 Kudos

Hi Stefan,

We have developed application which is able to interactively update saplogon.ini file according to users needs. User can select systems which should be visible in saplogon offer. Because aplication backend has to connect to client's machine it needs to know its IP address. Because we have used webdynpro as user interface (backend is in R/3) we need to determine client's IP address here.

I have made a workaround using Java servlet but I am interested in possible webdynpro solutions.

Thanks and Regards

Zdenek

Former Member
0 Kudos

Yes you can with an internal webdynpro api


String remoteHost = TaskBinder.getCurrentTask().getWebContextAdapter().getHttpServletRequest().getRemoteHost();

To get this to build or even see the getHttpServletRequest() method you should have the servlet jar file in the classpath. Even if you run into errors during build continue to deploy ,it should work fine

Regards

Pran