views:

54

answers:

1

This has been messing me up hard i have been trying to solve this problem and after writing a dummy app to check headers and pointing my code to it i notice HttpWebRequest will completely ignore my user agent when i POST data.

Why? How do i solve this?

+1  A: 

Presumably you are using HttpWebRequest.UserAgent property to set this, right? Just a guess, but I note that MSDN states:

Note: The value for this property is stored in WebHeaderCollection. If WebHeaderCollection is set, the property value is lost.

Could this be it?

Dan Diplo