Zabaware Support Forums

Zabaware Forums => Ultra Hal Assistant File Sharing Area => Topic started by: onthecuttingedge2005 on September 14, 2003, 10:51:50 pm

Title: Hal's new favorites script.
Post by: onthecuttingedge2005 on September 14, 2003, 10:51:50 pm
'[Updated] on 9-23-03
'Here ya go guys.

'Hal has detected new favorites from the User and made them his.

'Hals new favorites   
If HalBrain.TopicSearch(OriginalSentence, WorkingDir & "MYFAVORITES.brn") = "TRUE" Then
AnswerSent = "" & Trim(OriginalSentence)
HalBrain.AppendFile WorkingDir & "FAVORITESLIST" & ".brn", AnswerSent
End If
   
If HalBrain.TopicSearch(OriginalSentence, WorkingDir & "MYFAVORITES.brn") = "TRUE" Then
TalkFavorites = HalBrain.ChooseSentenceFromFile(WorkingDir & "FAVORITESLIST.brn")
      GetResponse = TalkFavorites & vbCrLf
      DebugInfo = DebugInfo & "The user is talking about new favorites: " & TalkFavorites & vbCrLf
      Else
      DebugInfo = DebugInfo & "Hal has found nothing about new favorites: " & TalkFavorites & vbCrLf
   End If

'two files attached MyFavorites.brn and FavoritesList.brn
'download to your default folder. MyFavorites.brn is the
'detector file and FavoritesList.brn is the file that's written
'to and read from when new favorites are found.
'Best of wishes and new discoveries.
'Jerry.

Download Attachment: (http://images/icon_paperclip.gif) FavoritesList.brn ("http://www.zabaware.com/forum/uploaded/onthecuttingedge2005/200391422485_FavoritesList.brn")
491 Bytes


Download Attachment: (http://images/icon_paperclip.gif) MyFavorites.brn ("http://www.zabaware.com/forum/uploaded/onthecuttingedge2005/2003914233442_MyFavorites.brn")
3.22 KB
Title: Hal's new favorites script.
Post by: Larry on September 15, 2003, 04:40:18 am
Thanks!!! This is so cool... wish I had figured that one out!!!

Any more goodies???