Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7494059
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T17:18:03+00:00 2026-05-29T17:18:03+00:00

Edited my code to use WebClient…still doesnt work string hhtmlurl = /Thumbnail.aspx?productID=23&Firstname=jimmy&lastnight=smith; string strFileName

  • 0

Edited my code to use WebClient…still doesnt work

string hhtmlurl = /Thumbnail.aspx?productID=23&Firstname=jimmy&lastnight=smith;

string strFileName = string.Format("{0}_{1}", hfUserID.Value, Request.QueryString["pid"].ToString() + documentID.ToString());
WebClient client = new WebClient();
client.DownloadFile("http://www.url.ca/" + hhtmlurl.Value + "card=1", strFileName);
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T17:18:04+00:00Added an answer on May 29, 2026 at 5:18 pm

    Try this method. This will give you string return for the entire html content. Write this string in whatever file you want

    public string GetHtmlPageContent(string url)
        {
            HttpWebResponse siteResponse = null;
            HttpWebRequest siteRequest = null;
            string content= string.Empty;
    
            try
            {
                Uri uri = new Uri(url);
                siteRequest = (HttpWebRequest)HttpWebRequest.Create(url);
                siteResponse = (HttpWebResponse)siteRequest.GetResponse();
    
                content = GetResponseText(siteResponse);
            }
            catch (WebException we)
            {
                // Log error
            }
            catch (Exception e2)
            {
                // Log error
            }
    
            return content;
        }
    
            public string GetResponseText(HttpWebResponse response)
        {
            string responseText = string.Empty;
    
            if (response == null)
                return string.Empty;
    
            try
            {
                StreamReader responseReader = new StreamReader(response.GetResponseStream());
                responseText = responseReader.ReadToEnd();
                responseReader.Close();
            }
            catch (Exception ex)
            {
                // Log error
            }
    
            return responseText;
        }
    

    Hope this will help you.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Update: Edited code example to use AutoA for the workaround (which was the original
Edited Now my code is like this: #!/usr/bin/perl # import packages use Net::POP3; use
I have HTML code edited by FCKEditor stored in a database and would like
using Matt's util code (a bit edited for Unicode text) public class GridViewExportUtil {
SOLVED. Code has been edited to reflect solution. Given the following GridView : <asp:GridView
In Resharper I edited the inspection severity of the 'use var keyword when possible'
I edited my original text to demostrate my entire set of code for those
I'm trying to reutilize code that generates FILE fields for use when something is
UPDATE: I've edited the code below to show what I was using when I
I am trying to use ajax like below; jquery code: $(a.generate).click(function(){ $.ajax({ data: {tag:

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.