Home | Blog | Software | Reviews and Features | Forum | Help | Donate | About us
topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • December 06, 2016, 04:22:05 AM
  • Proudly celebrating 10 years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Author Topic: Problem with Browser object in C#  (Read 3503 times)

Carl00

  • Participant
  • Joined in 2008
  • *
  • default avatar
  • Posts: 8
    • View Profile
    • Donate to Member
Problem with Browser object in C#
« on: July 18, 2008, 09:30:27 AM »
OK.. i have a weird problem.

I made a C# program which uses the Browser Object contained in .Net (i assume this creates an instance of an IE browser)

Now, it loads webpages perfectly on my PC, however when i run the program on any other pc , the browser always shows "the page can not be displayed"
Strangely though, if you use IE standalone, it works perfectly.

I even disabled all firewalls and installed the latest version of IE, but it still shows the same error message.

I dont understand this.. are there some settings required?

ps. .Net framework 3.5 is also installed on all Pcs.. program loads/works perfectly, except for teh browser part..

wreckedcarzz

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 1,623
    • View Profile
    • Donate to Member
Re: Problem with Browser object in C#
« Reply #1 on: July 18, 2008, 03:40:34 PM »
Make sure you are using all needed Includes (just a thought) and that the settings for the browser are not hard coded to your PC (mistakes happen)... :-\ just some thoughts (I do VB .NET, not C#, but same OOP system),

And yes, it uses the version of IE present on the computer.

Carl00

  • Participant
  • Joined in 2008
  • *
  • default avatar
  • Posts: 8
    • View Profile
    • Donate to Member
Re: Problem with Browser object in C#
« Reply #2 on: July 18, 2008, 10:22:28 PM »
I haven't coded in any extra settings / properties.. its just the default browser object. All im doing is navigating using the inbuilt webbrowserobj.Navigate("www.blahblah.com" ); function


What includes? I assumed everything would be in the .net framework? Am I missing something?

app103

  • That scary taskbar girl
  • Global Moderator
  • Joined in 2006
  • *****
  • Posts: 5,666
    • View Profile
    • App's Apps
    • Read more about this member.
    • Donate to Member
Re: Problem with Browser object in C#
« Reply #3 on: July 19, 2008, 06:15:33 AM »
Not sure how you are transferring the files to another pc, but try this:

  • Right click the .exe file in Explorer and select properties.
  • See if there is a button that says "Unblock" right below the Advanced button on the General tab.
  • If there is, click it and then click Apply and then OK.
  • Try your file again and see if it works.

If that doesn't work, make sure there isn't a "#" character in the file's path. If there is, change it.

Carl00

  • Participant
  • Joined in 2008
  • *
  • default avatar
  • Posts: 8
    • View Profile
    • Donate to Member
Re: Problem with Browser object in C#
« Reply #4 on: July 19, 2008, 06:59:50 AM »
Thanks for your replies guys,
I figured out the problem though it doesnt make any sense logically..

I set the property "ScriptErrorsSuppressed" = true; and it worked fine.

Doesnt make sense why i couldnt browser at all without that, considering it worked fine on my PC.

wreckedcarzz

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 1,623
    • View Profile
    • Donate to Member
Re: Problem with Browser object in C#
« Reply #5 on: July 19, 2008, 04:12:39 PM »
At least you got it resolved, though! :Thmbsup: