views:

309

answers:

2

On the client machine I need to be able to somehow detect which sites the current user are looking at right now. I know the base URL of the sharepoint app, say sharepoint.thecompany.net but how the hack do I get the last requested url from the server? I have hit a dead stop when trying to iterate the current processes and the casting the iexplorer process to something I can work with, I just don't know which kind of object to cast the process to :-(

I hope to implement this logic in a C# assembly what should run on the client box.

Any other approach that might work?

Thanks in advance

+1  A: 

Duplicate of your previous question?

http://stackoverflow.com/questions/206775/how-do-i-get-the-urls-from-any-tab-in-any-open-browser

BoltBait
similar but far from identical. I am still pondering the same problem, but now I am looking outside the box. The "get URL from browser" approach is dead
Kasper
A: 

WatiN will allow you to attach to IE instances and get the current url from them. It will also allow you to do the same with Firefox instances.

It might be more efficient however to try to get requested urls at the network level using a wireshark type concept where you are just listening to http traffic on the computer and keeping track of the urls but a solution like that is a bit over my head.

EDIT: I came across this while looking for a solution: http://www.codeproject.com/KB/IP/networkmonitor.aspx From what I can see I would think you could adapt the monitoring code to monitor and look for http request packets and parse the headers for the url information you need.

mockedobject