If you're using .NET 3.5, consider using LINQ (Language Integrated Query).
Assume that you have a customer database. The following query would select the customers in Oregon:
Customer[] Customers = GetCustomers();
var query =
from c in Customers
where c.State == "Oregon"
select c;
Quick and easy!
John
User Profile
Collapse
-
If you have access to the proxy, forward the appropriate port to your server.
If you have access to your firewall, you can do one of two things: either forward the appropriate port to your server, or move your server into the DMZ.
Have fun!
John
[link removed]Leave a comment:
-
Spot on. For each url, use the code at http://msdn2.microsoft .com/en-us/library/system.net.http webrequest.getr esponse.aspx, check the status code of the response. 200 is OK, while 404 is the typical broken link. Other status codes will require some judgement.
John
http://blogs.msdn.com/usisvde/...Leave a comment:
-
See the code at http://www.thescripts. com/forum/showthread.php? p=3075511#post3 075511 for a more typical use of HttpWebRequest.
John
http://blogs.msdn.com/usisvde/...Leave a comment:
-
Unfortunately, you really can't do that -- there is a bunch of state internal to a socket, so you can't just copy the 5-tuple information (type of stream, source ip and port, destination ip and port) to another socket and have it work.
Since your API is already handling the socket, perhaps you should use a stream (System.IO.Stre am) to handle the in and out byte streams.
John
http://blogs.msdn.com/usisvde/...Leave a comment:
-
Your question is a bit unclear. If you want the router of the destination -- that is, the last routable ip address at the destination, look at the destination ip.
For the router on your end, do a traceroute and find the first routable ip address (that is, one that doesn't start with 192.168, 10., or 172.16). Or, roll your own traceroute by setting TTL to 1, then, 2, and so on.
John
http://blogs.msdn.com/usis...Leave a comment:
No activity results to display
Show More
Leave a comment: