1.    02 May 2016 #1

    Script to get IP address and send email every so often


    Hi there

    any decent programmers out there who can generate a script for me that does the following :

    1) Get my IP address
    2) send an email say every 30 mins (or user settable) to a FIXED email address - or even a text to a mobile phone.

    The reason I want this is that services like no-Ip are going "PAY FOR" or you get some silly restrictions on the free stuff like re-register every few days or the IP address detection program runs every minute which is a nonsense --with Fibre connections to your ISP the IP address doesn't change much (if at all) while you are connected to the Internet - but only at boot.

    That way I can access my home computer without needing to get a commercial domain etc -- on the LOCAL LAN the server has a fixed IP address so port forwarding isn't a problem for using things like RDP.

    Please don't suggest TEAMVIEWER -- don't want or need it. My upload speed on ISP is perfectly good enough for me to be independent of this type of service.

    Even if you run say an apache (LAMP / WAMP) server you will get access to it easily enough via its IP address of you know it.

    Surprised some of the experienced coders out there haven't done this type of thing. Should be easy enough to issue a command to get your external IP address (Router gives you that without even needing Internet access from the HOST) , push the output say to a notepad file and then send email with the notepad attachment.

    I'm not a coder --I know what to do --but not how to do it !! so any help there would be fine --don't care if it's C, C++, VB or anything so long as it works !!

    Cheers
    jimbo
      My ComputerSystem Spec
  2.    02 May 2016 #2
    Join Date : Jan 2014
    Oak Ridge TN, USA
    Posts : 24,523
    Windows 10 Pro x64

    Give me some time and I'll look into this today. I need to do some things first today.. like waking up.

    I'll try it out in both VB.Net and AutoIt. I need to install .Net back on my PC and that will take an hour or so,.

    Jeff
    Last edited by BunnyJ; 02 May 2016 at 05:20. Reason: Added content...
      My ComputerSystem Spec
  3.    02 May 2016 #3

    Quote Originally Posted by BunnyJ View Post
    Give me some time and I'll look into this today. I need to do some things first today.. like waking up.

    I'll try it out in both VB.Net and AutoIt.

    Jeff
    Hi there

    @Bunny

    For Linux there's a simple command that returns your IP address (external)

    dig +short myip.opendns.com @ReSolver1.opendns.co


    This though seems to work for Windows

    run this command as a normal user

    Click image for larger version. 

Name:	IP.png 
Views:	0 
Size:	133.0 KB 
ID:	77840

    the major problem now is to generate an email (in Batch) or a message to a mobile phone
    capturing linux output from the console is easy -- however I'm using OUTLOOK in Windows for email --Linux email clients still UGH UGH !!.

    Cheers
    jimbo
    .
      My ComputerSystem Spec
  4.    02 May 2016 #4
    Join Date : Jan 2014
    Oak Ridge TN, USA
    Posts : 24,523
    Windows 10 Pro x64

    It's really shouldn't be that hard to get this done with either VB or AutoIt.

    I'll PM you later on with more information.
      My ComputerSystem Spec
  5.    02 May 2016 #5

    Quote Originally Posted by BunnyJ View Post
    It's really shouldn't be that hard to get this done with either VB or AutoIt.

    I'll PM you later on with more information.
    Hi there

    Thanks !!!

    Cheers
    jimbo
      My ComputerSystem Spec
  6.    02 May 2016 #6
    Join Date : Dec 2015
    Posts : 6,405
    Windows10

    I use this organisation that does not time out, and you can set up "dial home" interval.

    http://www.freedns.afraid.org

    I actually set up my raspberry pi to basically call ddns server every so often and update my external ip address.

    I can't remember exactly how I did it but these links give more info.

    https://freedns.afraid.org/scripts/freedns.clients.php

    This gives some windows clients as well, but I just leave my pi on 24/7, and I have never had a problem

    TechJawab.com: Setup Dynamic DNS / DynDNS for *FREE* on Raspberry Pi / Ubuntu

    Now with bash on Insider versions .......
      My ComputerSystem Spec

 


Similar Threads
Thread Forum
Email address
I tried to send an email using live.com, my Microsoft address, and their address was invalid yet when I put the exact address the recipient in Gmail it worked. Any explanations please. Thank you Peter
Browsers and Email
Default 'send as' email address
Staff have their own email address (name@) and 'send as' permissions for another one (info@). Is it possible to set a default send as address so the employees don't accidentally email from their own account when i'd prefer them to use info@ by...
Browsers and Email
How to enable 'send as' in Outlook (Office 365 email)
I know this is predominantly a Windows forum but given it's all MS, the 365 forum is pants and you guys are constantly so helpful I thought i'd give it a shot here. We've got a main info@ email address (which is actually just my own as the boss,...
Software and Apps
Solved MS Outlook will not send email after windows 10 upgrade
MS Outlook will not send email after windows 10 upgrade I loaded windows 10 from windows 7 and found that MS outlook would not send email. After searching google I found a reference to the SFC tool. close outlook Open a command prompt in the...
Browsers and Email
Verify your email address
When I try to download any app, "I get the prompt "Verify your email address." I originally submitted an email address and password when I set up windows 10. Now, I am sent a link directing me to a website to verify my password. The password (which...
General Support
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 18:10.
Find Us
Twitter Facebook Google+ Ten Forums iOS App Ten Forums Android App



Windows 10 Forums