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

  • SEARCH
  • Home
  • 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 6183737
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T01:25:02+00:00 2026-05-24T01:25:02+00:00

I am trying to access a website via webclient in .net but I am

  • 0

I am trying to access a website via webclient in .net but I am getting an error message saying this:
“Microsoft Online Services requires JavaScript to sign in. This web browser either does not support JavaScript, or scripts are being blocked.”

Here is the code I am using to access the website:

string url = "myUrl";
WebClient client = new WebClient();
client.Headers.Add("user-agent", "Mozilla/5.0 (Windows NT 6.1; rv:5.0.1) Gecko/20100101 Firefox/5.0.1");
client.Credentials = new NetworkCredential("username", "Password");          
string lines = client.DownloadString(url);   

Any help is appreciated. Should I change the user agent or try something else?
Thanks in advance, Laziale

  • 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-24T01:25:03+00:00Added an answer on May 24, 2026 at 1:25 am

    You might want to use a System.Windows.Forms.WebBrowser to parse the Javascript.
    A web client only attempts downloads the file.
    Javascripts are not processed on the server… They are processed on the client.

    So, with your WebClient download the URL file to a file in the computer and use the WebBrowser to Navigate to the downloaded file.
    It will parse the Javascripts and other stuff and after finished (there must be an event for that) you can retrieve the (parsed) content and work with it.

    That whole “you must enable Javascript thing” is hidden by a Javascript.
    It’s not the server the one who detects it.

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

Sidebar

Related Questions

I'm trying to access the Reporting Services via Web Services in my Visual Studio
I'm trying to automate access to a website that get reports from a Microsoft-IIS/6.0
I'm trying to access a website with python through tor, but I'm having problems.
I'm trying to access an internal website that requires windows authentication. I've tried going
Im trying to access the Magento customer session in another part of my website.
I'm trying to create a DLL using a Dataset.XSD file to access my website's
I'm trying to access the Facebook API Admin.getMetrics method via jQuery. I'm correctly composing
I'm trying this with javascript, but it's possible there is an easier/better way. I
I'm trying to access a website using my login credentials through an iPhone app
I'm trying to access the mssql database of my website which a web design

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.