This has just gotta be dead simple. I have a web page that processes files on the server. I'm trying to call it and simply send the filename on the URL to kick it off but it's only calling the notificatin URL and not calling my parameters. What am I doing wrong?
private void Notify(IDictionary config, String fn)
{
//check to see if a notification url was specified
if (string.IsNullOrEmpty((String)config["notificationUrl"]))
{
log.Warn("No 'notificationUrl' specified. No notification generated.");
}
else
{
WebRequest wr = WebRequest.Create(string.Format(config["notificationUrl"].ToString() + "?file=" + fn));
wr.Method="GET";
HttpWebResponse hwr = (HttpWebResponse)wr.GetResponse();
if (hwr.StatusCode != HttpStatusCode.OK)
throw new Exception("Upload File created, but HTTP notification url returned status code: " + hwr.StatusCode.ToString());
}
}