Lotus Script
I am running an agent that updates my RSS feeds. When I run it locally it runs fine but when I schedule it to run on our server it doesn't retrueve anything from the Web, help!
CODE
Sub GetnUpdateFeed(Document As NotesDocument)
On Error Goto errGetnUpdateFeed
Dim strtext As String
Dim session As New NotesSession
Set richStyle = session.CreateRichTextStyle
Dim richText As New NotesRichTextItem(document, "BODY")
richStyle.PassThruHTML = True
Call richText.AppendStyle(richStyle)
Dim XMLDOC As Variant
Set xmlDoc=CreateObject("Msxml2.DOMDocument.4.0")
xmlDoc.async="false"
url=document.GetItemValue(|RSS_Feed_URL|)
strtitle=document.GetItemValue(|Subject|)
Dim TitleString As String, GoogleString As String
Dim positionOfChar As Long
If Trim(url(0))="" Then Exit Sub
xmldoc.load(url(0))
xpathtitle="/rss/channel/item/title"
Set nodes_title=xmlDoc.selectNodes(xpathtitle)
xpathlink="/rss/channel/item/link"
Set nodes_link=xmlDoc.selectNodes(xpathlink)
xpathdescription="/rss/channel/item/description"
Set nodes_description=xmlDoc.selectNodes(xpathdescription)
Forall x In nodes_title
v = v + 1
'Print "V = " & V
'If positionOfChar& = 0 Then
' Call richText.AppendText(Cstr(v) + ". " + x.text)
Call richtext.AddNewline(1)
'End If
p=0
Forall b In nodes_link
p=p+1
'Print "P = " & P
If p=v Then
Call richtext.AddTab(1)
'If positionOfChar& =0 Then
' Call richText.AppendText(b.text)
'End If
Call richtext.AddNewline(1)
g=0
Forall e In nodes_description
g=g+1
'Print "G = " & G
If g=v Then
Call richtext.AddTab(2)
Call richText.AppendText(e.text)
'Print "Just written e.text"
Call richtext.AddNewline(2)
Exit Forall
End If
End Forall
Exit Forall
End If
End Forall
'Print "RSS-Saving document"
Call document.save(True,False)
End Forall
'Print "AT BOTTOM OF FOALL"
Exit Sub
errGetnUpdateFeed:
'Print "Sub errGetnUpdateFeed - Error " & Err() & ": " & Error() & "Erl:" & Erl()
Resume Next
End Sub



