I have been looking for code that I can look at
for an idea on how to take a list of websites fed
to a textbox that I could ping against a list of RSS
feed sites.
Does anyone know how to accomplish something
like this in VB.net 2008?
Chris
Printable View
I have been looking for code that I can look at
for an idea on how to take a list of websites fed
to a textbox that I could ping against a list of RSS
feed sites.
Does anyone know how to accomplish something
like this in VB.net 2008?
Chris
Currently all I can think of is adding a single textbox and button to a form and using system.diagnostics.process.start (textbox1.text) where I'd input the url I'd like to post to but I can't figure out how to add a list of urls to post to using the input from the textbox. I'm very much new to coding so bear with me.
Chris
The Framework includes a Ping class so the pinging isn't a problem. What is the actual question? Is it how to allow the user to provide a list of addresses? If so then a TextBox, a Button and a ListBox will do the job. Alternatively, you could use a DataGridView with a single column. That way there's always an empty cell at the bottom for new input. Whenever the user enters a new value the grid will automatically add a new empty cell for the next input.
What I ultimately am trying to accomplish is a form where I preload a list of websites that I will ping rss feeds that end user inputs into the form. So end user will input a series of rss feeds into form which will be saved and then once the button is pressed it will go down the list and ping each input rss feed to the list of rss ping services.
I'm new to coding so I'm not quite sure what code to use. Is there any resource to find what code I would be using to accomplish this task? I'm learning this by myself and I appreciate all your help!
Chris
here is a start. take this, modify it (listbox, button), and post that code with additional questions.
Code:If My.Computer.Network.Ping("www.yahoo.com") Then
MsgBox("Server pinged successfully.")
Else
MsgBox("Ping request timed out.")
End If
Great. One question, how do I get it to take a list of user input rss feeds and go down that list against the rss ping services?
I could ultimately use something like pinggoat.com to ping them for me but I'd like to have both options available for user input.
PingGoat posts look like this:
I have no idea how to put that http request along with the user input to create a valid post.Code:http://pingoat.com/index.php?pingoat=go&blog_name=test&blog_url=http%3A%2F%2Fwww.test.com&rss_url=http%3A%2F%2Ftest.com%2Fa.xml&cat_0=0&id[]=0&cat_1=0&cat_2=0
Chris
you can't ping a service, you can ping a site i.e. pingoat.com
you may need something like this
http://aspnet.4guysfromrolla.com/articles/031903-1.aspx
Sure, that is what I meant. Sorry. I currently use a commercial software
to do this for my sites but I'm thinking that it's best for me ( in order to learn coding) to learn to do this myself for applications that I am interested in.
Kinda a learn as you go type deal. :-)
Chris
I'm trying to work out how to take the user input website addresses from textbox1.text and use your code to ping a site. Here is all I know how to
do:
vb Code:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim site As String site = TextBox1.Text
try this.Quote:
Originally Posted by cmmorris1
Ok, that works for pinging the site input in textbox1.text.
Perhaps I wasn't explaining this correctly. I want to allow
a user to input a website into the textbox and then it will
ping / post to an rss service. Not actually ping the site like
ipconfig /ping but ping as in post the url to an rss service
for updating content.
Update: That code didn't work. I either get a message saying
it timed out or I get an unhandled pingexception.
Chris
post code for ping failure
see post #8 for RSS
Post number 8 has nothing to do with what I'm looking for.
Also, I gave an example using pinggoat.com service to ping
an rss feed but have no idea how to incorporate the input
url into that http request. See post 6
Here is a sample list of sites I want to post to using the input
rss feed from the user:
Code:http://www.popdex.com/addsite.php
http://rpc.pingomatic.com/
http://rpc.weblogs.com/RPC2
http://www.a2b.cc/setloc/bp.a2b
http://api.feedster.com/ping
http://api.my.yahoo.com/RPC2
http://www.blogdigger.com/RPC2
http://www.blogshares.com/rpc.php
http://www.blogstreet.com/xrbin/xmlrpc.cgi
http://ping.blo.gs/
http://ping.feedburner.com
http://ping.syndic8.com/xmlrpc.php
http://ping.weblogalot.com/rpc.php
http://rpc.blogrolling.com/pinger/
http://rpc.technorati.com/rpc/ping
http://topicexchange.com/RPC2
http://xping.pubsub.com/ping/
http://api.my.yahoo.com/rss/ping
http://api.moreover.com/ping
http://rpc.icerocket.com:10080/
http://1470.net/api/ping
http://bitacoras.net/ping
http://blogmatcher.com/u.php
http://bulkfeeds.net/rpc
http://coreblog.org/ping/
http://ping.amagle.com/
http://ping.bitacoras.com
http://ping.cocolog-nifty.com/xmlrpc
http://ping.rootblog.com/rpc.php
http://rcs.datashed.net/RPC2/
http://rpc.blogbuzzmachine.com/RPC2
http://www.bitacoles.net/ping.php
http://www.blogoole.com/ping/
http://www.blogoon.net/ping/
http://www.blogpeople.net/servlet/weblogUpdates
http://www.blogroots.com/tb_populi.blog?id=1
http://www.blogsnow.com/ping
http://www.lasermemory.com/lsrpc/
http://www.newsisfree.com/xmlrpctest.php
http://www.snipsnap.org/RPC2
http://www.weblogues.com/RPC/
http://xmlrpc.blogg.de/
Here is my project guys so you can see exactly what I am
looking to do. Anyone who knows about RSS pinging will
understand this.
Attachment 66808
Chris
If you are talking about something like this
RSS Ping
i suggest you contact the author(s)
http://www.google.com/search?q=rss+p...en-US:official
More like this.
http://www.badassrss.com/
Except posting rss feed to individual rss posting websites instead of
using a single service like pinggoat.com
I've fixed the remove item in listbox1 issue, how do I take the input
urls from listbox1 and ping the websites in listbox2?
Attachment 66809
Chris
What am I doing wrong here? I am trying to take urls input
into listbox1 and use a get request using the urls against listbox2
urls?
I know I am missing a lot of code here guys like a loop to cycle through allCode:Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
Dim site As String
site = ListBox1.Items
Net.HttpWebRequest.Create(site)
MsgBox("site updated")
End Sub
the input urls from listbox1 & 2. But I do not know how to construct this whole
thing. I really appreciate everyone's help though. :-)
This is my form layout and I need the urls input into listbox1 to use the get request against the urls in the listbox2 and loop until all urls in both boxes are finished.
http://www.vbforums.com/attachment.p...1&d=1222732721
Chris
Can someone help me figure out how to fix this? I have a ping button on a form that I want to take the input from feeds to ping bog (listbox1) and ping these rss services from (listbox2) in a loop. Here is the code that I currently have, I can't figure out how to use the feeds in my listbox2 so I have some hard coded in the Ping button.
vb Code:
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click Dim listToPing As New ArrayList Dim pingURL As String = "" Dim blogURL As String = "" Dim blogName As String = "" With listToPing .Add("http://rpc.technorati.com/rpc/ping") .Add("http://api.feedster.com/ping") .Add("http://ping.feedburner.com") .Add("http://blog.goo.ne.jp/XMLRPC") .Add("http://ping.blo.gs/") .Add("http://ping.bloggers.jp/rpc/") .Add("http://ping.blogmura.jp/rpc/") .Add("http://ping.cocolog-nifty.com/xmlrpc") .Add("http://ping.syndic8.com/xmlrpc.php") .Add("http://rpc.blogbuzzmachine.com/RPC2") .Add("http://rpc.blogrolling.com/pinger/") End With For i As Integer = 0 To listToPing.Count - 1 Try pingURL = listToPing.Item(i).ToString Dim technoratiPing As Net.HttpWebRequest = CType(Net.WebRequest.Create(pingURL), Net.HttpWebRequest) technoratiPing.Method = "POST" technoratiPing.ContentType = "text/xml" Dim streamPingRequest As IO.Stream = CType(technoratiPing.GetRequestStream, IO.Stream) Dim xmlPing As Xml.XmlWriter = New Xml.XmlTextWriter(streamPingRequest, System.Text.Encoding.UTF8) xmlPing.WriteStartDocument() xmlPing.WriteStartElement("methodCall") xmlPing.WriteElementString("methodName", "weblogUpdates.ping") xmlPing.WriteStartElement("params") xmlPing.WriteStartElement("param") xmlPing.WriteElementString("value", blogName) xmlPing.WriteEndElement() xmlPing.WriteStartElement("param") xmlPing.WriteElementString("value", blogURL) xmlPing.WriteEndElement() xmlPing.WriteEndElement() xmlPing.WriteEndElement() xmlPing.Close() Dim technoratiPingResponse As Net.HttpWebResponse = CType(technoratiPing.GetResponse, Net.HttpWebResponse) Dim streamPingResponse As IO.StreamReader = New IO.StreamReader(technoratiPingResponse.GetResponseStream) Dim strResult As String = streamPingResponse.ReadToEnd streamPingResponse.Close() technoratiPingResponse.Close() Catch ex As Exception 'Add code here to flag a service as broken End Try Next End Sub