Last active
December 26, 2021 15:18
-
-
Save mdsaif45/bd1b658dca94c7cf9a409d2984b9c138 to your computer and use it in GitHub Desktop.
Revisions
-
mdsaif45 revised this gist
Dec 26, 2021 . No changes.There are no files selected for viewing
-
mdsaif45 created this gist
Dec 26, 2021 .There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,24 @@ Dim speaks, speech hour_now=hour(time) if hour_now > 12 or hour_now = 12 Then hour12 = hour_now - 12 ampm = "PM" Else hour12 = hour_now hourfinal = hour_now ampm = "AM" End If If hour12 = 10 Then hourfinal = "Ten" Elseif hour12 = 11 Then hourfinal = "Eleven" Elseif hour12 = 12 Then hourfinal = "Twelve" Elseif hour12 = 0 Then hourfinal = "Twelve" Elseif hour12 > 0 and hour12 < 10 Then hourfinal = hour12 End If speaks = "It is " & hourfinal & " o clock " & ampm Set speech=CreateObject("sapi.spvoice") speech.Speak speaks