?
Solved

TCP component

Posted on 2003-03-03
3
Medium Priority
?
217 Views
Last Modified: 2010-04-04
I want to control internet connection. I have read that I can control it by TCP.localip property. How  can I get TCP component for this.
0
Comment
Question by:eldarmusayev
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 1

Expert Comment

by:Wax0r
ID: 8057903
Hi,

Please be more specific on what you want to do rather than saying "control internet connection".

Do you want to be able to disconnect from the internet/network?

Do you want to obtain the local IP Address? (which is what localip is for, nothing else).

etc.
0
 

Author Comment

by:eldarmusayev
ID: 8063393
Program must send data to our office over internet when text file is changed. Program must know if internet is open or closed (Internet can be delivered over network or diulup). If closed it tries to use the modem. How can it know?  
0
 
LVL 1

Accepted Solution

by:
Wax0r earned 150 total points
ID: 8063816
To send data from one place or the other you can use the TClientSocket and TServerSocket components that come with Delphi.

To detect whether a file has changed or not simply place a timer somewhere and do CRC checks at every interval, if the 'new' CRC value differs from the 'old' one, the file has changed so you should send it over to the server.

You can detect whether the internet is up and running by sending out a PING (ICMP echo request) to a host you can rely on being online, if it returns you have a working internet connection so you can do whatever you want to do that needs the internet.

If it's not opened you can use some delphi code to do a dialup (RAS components aplenty, try torry.ru)..

that pretty much answers it
0

Featured Post

Independent Software Vendors: 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

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …
How to fix incompatible JVM issue while installing Eclipse While installing Eclipse in windows, got one error like above and unable to proceed with the installation. This video describes how to successfully install Eclipse. How to solve incompa…
Suggested Courses

801 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