Announcement

Collapse
No announcement yet.

VB.NET Script - Bible Verse of the day

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    VB.NET Script - Bible Verse of the day

    (Edited on 1-25-21) to remove some unicode characters before speaking


    -------------------------------------------------------------------------------
    The site i was using changed the RSS to requiring a login... so i found another RSS feed.

    The new feed location is : https://www.biblegateway.com/votd/get/

    The script is as follows (Edited on 1-25-21)

    Code:
    Imports System.IO
    Imports System.Text.RegularExpressions
    
    Sub Main(parm as object)
    
    
    
    Dim result As String = [String].Empty
    
    Dim m_xmld As XmlDocument
    Dim m_node As XmlNode
    Dim CHverse as xmlNode
    dim tverse as xmlNode
    
    
    
    m_xmld = New XmlDocument
    m_xmld.Load("https://www.biblegateway.com/votd/get/")
    
    CHverse = m_xmld.SelectSingleNode("votd/reference")
    
    tverse = m_xmld.SelectSingleNode("votd/content")
    
    
    result = tverse.InnerText
    
    result = Replace(result, "—", " . ") ' emdash
    result = Replace(result, "“", " . ")  ' left quote
    result = Replace(result, "”", " . ") ' right quote
    
    
    
    hs.speak ("The Verse for the day is from " & CHverse.InnerText.replace(":"," verse ") & ". The Verse is . . " & result ,TRUE)
    'hsp.waitms(250)
    
    hs.speak (". . . . . Again; This verse was from " & CHverse.InnerText.replace(":"," verse "),true )
    
    
    End Sub
    Last edited by ArbWare; January 25, 2021, 11:20 AM. Reason: To remove some unicode text before hs speak.. it was coming over the speaker as "8220", etc
    Regards,

    Andrew B.

    #2
    Thanks.
    I've been using Jon00 RSS feed on these:
    http://feeds.feedburner.com/hl-devos-dw?format=xml
    http://feeds.feedburner.com/hl-int-tv-en

    It has worked well but weeding out all of the stuff you don't want spoken has been a challenge.


    ~Bill

    Comment

    Working...
    X