Académique Documents
Professionnel Documents
Culture Documents
3)Once Signed in click over your profile pic and goto account
settings. Now copy the Access Token which is unique code to
communicate with your device and keep it safe.
Code:
_SECTION_BEGIN("PushBullet");
EnableScript("VBScript");
<%
'Your Message
Message = Message_Text
objXmlHttpMain.send strJSONToSend
'Store response
'msgbox(objXmlHttpMain.responseText)
'response.Write (objXmlHttpMain.responseText)
alert("Hi")
End Sub
%>
pb = GetScriptObject();
if
(LastValue(ValueWhen(Ref(Buy,-1),BarIndex())==BarIndex())
AND StaticVarGet(Name()+GetChartID()+"buyAlert")==0 )
{
pb.PushBullet("Buy Alert in " +Name() + " :
BuyPrice Value is " + BuyPrice + " Time " +
TimeNum());
StaticVarSet(Name()+ GetChartID() + "buyAlertBar",
LastValue(TimeNum()));
}
if (LastValue(TimeNum()) == StaticVarGet(Name()
+GetChartID()+"buyAlertBar"))
StaticVarSet(Name()+GetChartID()+"buyAlert",1); //
alert was triggered, no more alerts on this bar
else
StaticVarSet(Name()+GetChartID()+"buyAlert",0); //
new bar formed, and alerts can be trigered.
if
(LastValue(ValueWhen(Ref(Sell,-1),BarIndex())==BarIndex()
) AND StaticVarGet(Name()+GetChartID()+"buyAlert")==0 )
{
pb.PushBullet("Sell Alert in " +Name() + " :
SellPrice Value is " + SellPrice + " Time " +
TimeNum());
StaticVarSet(Name()+ GetChartID() + "sellAlertBar",
LastValue(TimeNum()));
}
if (LastValue(TimeNum()) == StaticVarGet(Name()
+GetChartID()+"sellAlertBar"))
StaticVarSet(Name()+GetChartID()+"sellAlert",1); //
alert was triggered, no more alerts on this bar
else
StaticVarSet(Name()+GetChartID()+"sellAlert",0); //
new bar formed, and alerts can be trigered.
_SECTION_END();
6)Now Replace xxxxxxxxxxxxxx in line 25 with your Secure Access
token