News:

BB code in posts seems to be working again!
I haven't turned on every single tag, so please let me know if there are any that are used/needed but not activated.

Main Menu

USERUI Function

Started by Yacine, May 23, 2010, 03:00:06 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Yacine

http://msdn.microsoft.com/en-us/library/ms195645(office.12).aspx says:
Quote
Evaluates one of the two expressions depending on the value of state.
USERUI(state,defaultexpression,userexpression)
Remarks
If state is 0, the USERUI function evaluates the defaultexpression. If state is 1, it evaluates the userexpression.
Example
USERUI(1, if(Width>6in, 6in, Width), Width*0.75)
Evaluates the expression Width*.075 and returns the result.

Has anyone played with this function? It looks to me as it does the same as a regular IF. What is it intended for?

Yacine

Browser ID: smf (is_webkit)
Templates: 4: index (default), Display (default), GenericControls (default), GenericControls (default).
Sub templates: 6: init, html_above, body_above, main, body_below, html_below.
Language files: 4: index+Modifications.english (default), Post.english (default), Editor.english (default), Drafts.english (default).
Style sheets: 4: index.css, attachments.css, jquery.sceditor.css, responsive.css.
Hooks called: 140 (show)
Files included: 32 - 1207KB. (show)
Memory used: 1020KB.
Tokens: post-login.
Cache hits: 13: 0.00139s for 26,766 bytes (show)
Cache misses: 2: (show)
Queries used: 17.

[Show Queries]