WebSite Blocker
Do you need something made? then ask in here.
Forum rules
Please LOCK your topics once you have found the solution to your question so we know you no longer require help with your query.
Please LOCK your topics once you have found the solution to your question so we know you no longer require help with your query.
i dont want the webbrowser control to navigate to a some sites that are listed in a listbox control
Hello this is not my code,
On form load put this code:
LoadBlockedSites()
The sub to load the blocked sites in a listbox:
Private Sub LoadBlockedSites()
ListBox1.Items.Clear()
Dim s As String
For Each s In My.Settings.BlockedSites
ListBox1.Items.Add(s)
Next
The code to Add a blocked site:
If txtBlock.Text = "" Then
'Do nothing
Else
My.Settings.BlockedSites.Add(AppManager.FixURL(txtBlock.Text))
LoadBlockedSites()
txtBlock.Text = String.Empty
End If
Also make a setting with the Name: BlockedSites
The type as: System.Collections.Specialized.StringCollection
Scope as: User
Value as:
<?xml version="1.0" encoding="utf-16"?>
<ArrayOfString xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<string>www.codenstuff.com</string>
</ArrayOfString>
;o CodeNStuff blocked?
I think thats it if you get errors, you might, Then contact me
THIS CODE DOES NOT WORK :(
On form load put this code:
LoadBlockedSites()
The sub to load the blocked sites in a listbox:
Private Sub LoadBlockedSites()
ListBox1.Items.Clear()
Dim s As String
For Each s In My.Settings.BlockedSites
ListBox1.Items.Add(s)
Next
The code to Add a blocked site:
If txtBlock.Text = "" Then
'Do nothing
Else
My.Settings.BlockedSites.Add(AppManager.FixURL(txtBlock.Text))
LoadBlockedSites()
txtBlock.Text = String.Empty
End If
Also make a setting with the Name: BlockedSites
The type as: System.Collections.Specialized.StringCollection
Scope as: User
Value as:
<?xml version="1.0" encoding="utf-16"?>
<ArrayOfString xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<string>www.codenstuff.com</string>
</ArrayOfString>
;o CodeNStuff blocked?
I think thats it if you get errors, you might, Then contact me

THIS CODE DOES NOT WORK :(
Just do something to check if the URL fits one of the sites in a ListBox, like if the URL contains www.codenstuff.com then it wont let you navigate to it by navigating to a kind of "error" web page made by you or other site.
lewisfroom wrote:Hello this is not my code,The Code Does Not Work :(
On form load put this code:
LoadBlockedSites()
The sub to load the blocked sites in a listbox:
Private Sub LoadBlockedSites()
ListBox1.Items.Clear()
Dim s As String
For Each s In My.Settings.BlockedSites
ListBox1.Items.Add(s)
Next
The code to Add a blocked site:
If txtBlock.Text = "" Then
'Do nothing
Else
My.Settings.BlockedSites.Add(AppManager.FixURL(txtBlock.Text))
LoadBlockedSites()
txtBlock.Text = String.Empty
End If
Also make a setting with the Name: BlockedSites
The type as: System.Collections.Specialized.StringCollection
Scope as: User
Value as:
<?xml version="1.0" encoding="utf-16"?>
<ArrayOfString xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<string>www.codenstuff.com</string>
</ArrayOfString>
;o CodeNStuff blocked?
I think thats it if you get errors, you might, Then contact me
THIS CODE DOES NOT WORK :(
You could do somthing link
Code: Select all
you can edit this to make it were is will read the text in a listboxIf textbox1.text = "" then
webbrowser1.navigate("")
end if
How about website un-blocker?
‼ <----- Copy it,it is together and if you backspace it it will both erase
☺☻♥♦♣♠•◘○◙♂♀♪♫☼►◄↕‼¶§▬↨↑↓→←∟↔▲▼ !"<-----Some Cool symbols.
♂<-----Boy Symbol
²ƽ<--------Mini 2 and 5!
ð<----Not sure what it is.
☺☻<-----Smiles
♪♫<----Music Notes
Others:ß┬ƒ○║■ã¿┼↑
☺☻♥♦♣♠•◘○◙♂♀♪♫☼►◄↕‼¶§▬↨↑↓→←∟↔▲▼ !"<-----Some Cool symbols.
♂<-----Boy Symbol

²ƽ<--------Mini 2 and 5!
ð<----Not sure what it is.
☺☻<-----Smiles
♪♫<----Music Notes
Others:ß┬ƒ○║■ã¿┼↑
Here's a example :
Let's say you want to block out all website except for CodenStuff's website
do the following :
If Textbox1.Text.contains("codenstuff") Then
WebBrowser1.Navigate(Textbox1.Text)
Else
Msgbox("Only CodenStuff Links Will Work")
End If
Let's say you want to block out all website except for CodenStuff's website
do the following :
If Textbox1.Text.contains("codenstuff") Then
WebBrowser1.Navigate(Textbox1.Text)
Else
Msgbox("Only CodenStuff Links Will Work")
End If
hello Martin64
,
i have been working on a project for this for you. i will post the files on heres as soon as i can, my father has my computer so i am not able to do this now.... :(
----------------------------------------------------------------------------------------------------------------------------------------
i added it

i have been working on a project for this for you. i will post the files on heres as soon as i can, my father has my computer so i am not able to do this now.... :(
----------------------------------------------------------------------------------------------------------------------------------------

You do not have the required permissions to view the files attached to this post.
Copyright Information
Copyright © Codenstuff.com 2020 - 2023