Solved

Enable/Disable Network Upload with C++ (or anything else?)

Posted on 2004-03-25
8
313 Views
Last Modified: 2013-12-03
I'm interested in writing a very simple program that can be scheduled to run every now and then, and if the network upload is enabled, it should disable it. If it's disabled, it should enable it.

I'm wondering where I should look, in which API, or in which language it would be easiest? I'm familiar with C++, and a little visual basic. Any tips?
0
Comment
Question by:dog78
  • 4
  • 3
8 Comments
 
LVL 5

Expert Comment

by:millsoft
ID: 10683327
Can you explain what you mean by "network upload"?
0
 
LVL 6

Expert Comment

by:joghurt
ID: 10685833
Do you mean the Upload Manager service, or the complete network connection (both upload and download)?
0
 

Author Comment

by:dog78
ID: 10696230
I'm specifically trying to solve a problem with my ISP and their rate limits. If I constantly upload, they have a fit. The tech support people recommended that for me to avoid having problems, I should cut the upload completely for at least seven minutes of every hour.

The download doesn't matter, but if it's easier to simply stop the whole interface, that's also acceptable.

In linux, I'd use an iptables rule to drop all outgoing packets. That's what I'm looking to do, here.
0
Salesforce Made Easy to Use

On-screen guidance at the moment of need enables you & your employees to focus on the core, you can now boost your adoption rates swiftly and simply with one easy tool.

 
LVL 5

Expert Comment

by:millsoft
ID: 10697019
So, you're trying to run a web server at home on a DSL or Cable modem and don't want to irritate the ISP?

0
 

Author Comment

by:dog78
ID: 10697029
To be exact, I'm trying to help a friend who uses his "unlimited" internet connection plan more than his ISP is comfortable with. I use Linux, he uses Windows. I thought, if I were to find the right API for this, I could write something trivial he could then schedule with the windows scheduler.
0
 

Author Comment

by:dog78
ID: 10697032
The problem is caused by his Bittorrent client.
0
 
LVL 5

Accepted Solution

by:
millsoft earned 50 total points
ID: 10697103
I don't know about linux/iptables, but the command line utility ROUTE can reroute packets.

If your computer is behind a firewall/router that can give the computer an IP address via DHCP you could effectively "turn off" the interface by typing:

IPConfig /Release

and turn it on by:

ipconfig /renew

Of course the interface isn't actually "disabled" but it may as well be.

0
 

Author Comment

by:dog78
ID: 10717304
Excellent solution. I'll schedule this as a BAT file.
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Visual Fox Pro commands 15 50
What .NET URL re-routing tool did I use? 2 75
VS2015 Redefinition errors 4 71
C# LINQ ForEach() question 6 54
This article shows a few slightly more advanced techniques for Windows 7 gadget programming, including how to save and restore user settings for your gadget and how to populate the "details" panel that is displayed in the Windows 7 gadget gallery.  …
After several hours of googling I could not gather any information on this topic. There are several ways of controlling the USB port connected to any storage device. The best example of that is by changing the registry value of "HKEY_LOCAL_MACHINE\S…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…

829 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