Visual Basic .NET Forums  
Click here to advertise with us

Go Back   Visual Basic .NET Forums > VB.NET > Windows Services

Windows Services Windows service development discussion

VB.NET Forums Newsletter Signup:
Email address:


Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 11-19-2008, 4:25 PM
VB.NET Forum Enthusiast
.NET Framework: .NET 2.0
 
Join Date: Jun 2007
Location: Norway - Drammen
Age: 22
Posts: 51
Reputation: 37
Levu is on a distinguished programming path ahead
Default Can't declare webbrowser windows service

Just started trying to make a windows service.
And i want it to check something on the internett, but i cant find the webbrowser thing..

This works regularly.. But not now.. Cant find the webbrowser..
Code:
Friend WithEvent browser1 as new webbrowser
Anyone know why?
__________________
Vb.net njub
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 11-19-2008, 5:31 PM
JohnH's Avatar
VB.NET Forum Moderator
.NET Framework: .NET 3.5 (VS 2008)
 
Join Date: Dec 2005
Location: Norway
Age: 37
Posts: 10,303
Reputation: 1315
JohnH has a reputation beyond reputeJohnH has a reputation beyond reputeJohnH has a reputation beyond reputeJohnH has a reputation beyond reputeJohnH has a reputation beyond reputeJohnH has a reputation beyond reputeJohnH has a reputation beyond reputeJohnH has a reputation beyond reputeJohnH has a reputation beyond reputeJohnH has a reputation beyond reputeJohnH has a reputation beyond repute
Default

WebBrowser is a Windows.Forms control, controls and forms is not used in windows services, which don't have UI and interact with active desktop, and don't have a windows message loop. You should be able to use a WebRequest/WebClient.
__________________
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 11-19-2008, 5:33 PM
VB.NET Forum Enthusiast
.NET Framework: .NET 2.0
 
Join Date: Jun 2007
Location: Norway - Drammen
Age: 22
Posts: 51
Reputation: 37
Levu is on a distinguished programming path ahead
Default

Meaning it wont work at all?
I can add it from the design view at the Service.vb (the start class of service)
__________________
Vb.net njub
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 11-19-2008, 11:47 PM
jmcilhinney's Avatar
VB.NET Forum Moderator
.NET Framework: .NET 3.5 (VS 2008)
 
Join Date: Aug 2004
Location: Sydney, Australia
Age: 40
Posts: 6,100
Reputation: 541
jmcilhinney VB.NET gold medalistjmcilhinney VB.NET gold medalistjmcilhinney VB.NET gold medalistjmcilhinney VB.NET gold medalistjmcilhinney VB.NET gold medalistjmcilhinney VB.NET gold medalistjmcilhinney VB.NET gold medalistjmcilhinney VB.NET gold medalistjmcilhinney VB.NET gold medalistjmcilhinney VB.NET gold medalistjmcilhinney VB.NET gold medalist
Default

Use a WebClient, which is a non-visual object that will get and send data over the Internet.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On





All times are GMT -4. The time now is 2:56 PM.

Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.3.2


For advertising opportunities click here.