Sunday, June 03, 2007

Prohibit users to trigger agents from web

When developing agents, it's easy to forget that every agent can be triggered from web with agentname?OpenAgent URL. Such agent invocation can cause unpredictable results.
To avoid this, developer has these 2 options:
1) Hide agent from web using property "hide design element from: Web browsers"
2) Programmatically find out if the agent is triggered from web and exit

Sub Initialize
ev=Evaluate("@ClientType")
If ev(0)="Web" Then Exit Sub 'Do not run agent if triggered from web
'here goes the rest of the code
'which will be executed in Notes client but not on web
End Sub

7 comments:

Niklas Waller said...

Great tip! Simple but so important. As you say, it's easy to forget.

Budi Febrianto said...

Thanks for the tip, it's a good tip.

Bryan Kuhn said...

nice little tip, I couldn't say I've used it before, but will come in handy as I'm now creating a lot more Web apps.

Anonymous said...

By the way, I recommend you buy the cheapest Atlantica online Gold and Atlantica power leveling from us where the prices here are low. So if you have the Atlantica Gold is useful to your level spear. Once you meet a real smart player with 2 spearmen team, their key to disable builds, and then you should buy Atlantica online Gold. In addition if you need to buy goods for your characters, the game provides you the cheap Atlantica online Gold. And the last, you can make the fun of the Atlantica online money in the Atlantica online world.
You need lots of kamas to enhance your game character. Follow the guide below, you will have a better experience in dofus kamas. Because of Bambooto attack with both earth and wind damage, with also heals kamas. There are some cheap kamas in the Dofus and that is very useful. The best part is that bulbiflor can drop bulbiflor magic bark, which sells for 50000 dofus gold and requires just 100 prospecting to get leveling my feca there got one between lv24 and lv46. They sell well kamas anytime too, so you can buy dofus kamas at anytime.

Anonymous said...

Now do you worried about that in the game do not had enough Sword of the New World Vis to play the game, now you can not worried, my friend told me a website, in here you can buy a lot Sword of the New World Gold and only spend a little money, do not hesitate, it was really, in here we had much cheap snw vis, we can sure that you will get the Sword of the New World money, quick to come here to buy vis.

Now do you worried about that in the game do not had enough twelve sky Gold to play the game, now you can not worried, my friend told me a website, in here you can buy a lot 12sky gold and only spend a little money, do not hesitate, it was really, in here we had much twelvesky Gold, we can sure that you will get the 12Sky Silver Coins, quick to come here to buy 12 sky gold.

virstock.com said...

Dofus Kamas|Prix Moins Cher Dofus Kamas|Kamas par allopass|Dofus kamas audiotel|Dofus kamas par telephone sur Virstock.com

Meilleur prix dofus kamas stock de dofus kamas

Prix moins cher dofus kamas
vente dofus kamas sur www.virstock.com

Kamas par allopass sur dofus kamas

Dofus kamas par telephone sur dofus kamas

Dofus kamas audiotel sur dofus kamas

http://www.virstock.com/jsp/comments.jsp dofus kamas vente

Le meilleur Blog sur Dofus Kamas MMORPG,trouver des astuces dofus kamas surdofus kamas

http://www.virstock.com

King Bayern Munich said...

Wow! Very good content, the analysis depth, so I understand! Like the authors way of thinking, and writing style! Compliment, ha ha! Thanks again for the selfless sharing of, I have learned a lot! At the same time I like LED Digital Sign and LED street light very much