?
Solved

Get IP address from Indy UDP server/client

Posted on 2004-09-14
3
Medium Priority
?
1,834 Views
Last Modified: 2010-04-05
Hi!

I use instances of TIdUDPServer and TIdUDPClient for broadcasting. How can I get the IP address of the computer my application is running on? Supposed to be easy?

Thanks!
0
Comment
Question by:__alex
  • 2
3 Comments
 
LVL 23

Accepted Solution

by:
Ferruccio Accalai earned 1000 total points
ID: 12052700
add to the uses clause IDStack;

Then anywhere call GStack.localaddress to obtain the local IP

see also a my previous answer to get a list of local addresses
http://www.experts-exchange.com/Programming/Programming_Languages/Delphi/Q_21117453.html#11968616

0
 
LVL 2

Author Comment

by:__alex
ID: 12052758
Great, enjoy the points!
0
 
LVL 23

Expert Comment

by:Ferruccio Accalai
ID: 12052780
Glad to have helped you :)

F68 ;-)
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
this video summaries big data hadoop online training demo (http://onlineitguru.com/big-data-hadoop-online-training-placement.html) , and covers basics in big data hadoop .
Is your data getting by on basic protection measures? In today’s climate of debilitating malware and ransomware—like WannaCry—that may not be enough. You need to establish more than basics, like a recovery plan that protects both data and endpoints.…
Suggested Courses

850 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question