Project

General

Profile

twitter.patch

patch - Anonymous, 09/29/2010 02:53 PM

View differences:

DomotiGa/Main.module (working copy)
91 91
PUBLIC iPrev_Year AS Integer
92 92
PUBLIC iDelayOccured AS Integer
93 93

  
94

  
94 95
' Timers
95 96
PUBLIC tMainFlush AS Timer
96 97
PUBLIC iMainFlushTime AS Integer = 3000
DomotiGa/Twitter.module (working copy)
15 15
PUBLIC hTweet AS Process
16 16

  
17 17
PUBLIC SUB PostTweet(sMessage AS String)
18

  
19 18
  ' if not enabled, return
20 19
  IF NOT Main.bTwitterEnabled THEN RETURN
21 20

  
22 21
  IF Main.ProgramExist("bti") THEN
23
    hTweet = SHELL "echo '" & sMessage & "'|bti" FOR READ AS "Tweet"
22
    hTweet = SHELL "echo '" & Hour(Main.dTime) & ": " & Minute(Main.dTime) & ": " & Second(Main.dTime) & ": " & sMessage & " '|bti" FOR READ AS "Tweet"
24 23
  ELSE
25 24
    Main.WriteLog(("You need to install the oauth library and bti cmd to use Twitter!"))
26 25
  ENDIF
......
41 40
    Main.WriteLog(("I have sent a Tweet to 'http://twitter.com/") & Main.sTwitterUser & "'.")
42 41
  ENDIF
43 42

  
44
END
43
END