Jump to content

Recommended Posts

Posted

I have a customer that is complaining that a program, known to us to work, will not send out reports via e-mail. Now this site has Routers locked down tighter then you can imagine because they had been cracked before. I wrote a simple program that logs internet connectivity and connectivity on the local network, and if anyone of the 5 points returns an error, a log is created listing the 5 IPs, the failure and the responce time of the sucessful pings. Now for this site that is locked down, I'm not getting an error log. So I did a test ping and the DOS prompt responded with a destination host unreacable. Now all I did to qualify an "error" is put @error in my code. Would a "destination host unreacable return something that AutoIT qualifies as an error?

Thanks in advance

Thanks for your time

 

Posted

According to the help file function ping sets @error = 2 when the host is unreachable:

"When the function fails (returns 0) @error contains extended information:

1 = Host is offline

2 = Host is unreachable

3 = Bad destination

4 = Other errors"

So what's your problem?

My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download
Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki
PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki
Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki

Standard UDFs:
Excel - Example Scripts - Wiki
Word - Wiki

Tutorials:
ADO - Wiki
WebDriver - Wiki

 

Posted (edited)

Just making sure I grasp this totally. The Ping Function has errors built in to it 1-4, so if I set a if statement to generate a .log when it sees an @error, the @error is a different macro that I didn't really need. I could have just set the function to look for the internal ping errors.

EDIT: Sorry this is a stupid question I'm not all together yet today

Edited by JayHawkfl

Thanks for your time

 

Posted

So the problem is solved?

My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download
Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki
PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki
Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki

Standard UDFs:
Excel - Example Scripts - Wiki
Word - Wiki

Tutorials:
ADO - Wiki
WebDriver - Wiki

 

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...