> Can you somehow use the selectmacro to replace the prompt in a script? > I want users to be able to choose amongst existing tiddlernames from a > list - The choice should be placed in the script for further > processing.
The functions: alert(), confirm(), and prompt() are built-in browser- supplied functions. They aren't rendered *in* the TW page, but rather display a completely separate dialog box. While that dialog box is displayed you *cannot* interact with any other part of the browser... not even to switch tabs. This is called "application modal" (because it creates a "mode" that applies to the entire application... in this case, the browser). In contrast, the <<select>> macro is defined in http://www.TiddlyTools.com/#ListboxPlugin and uses javascript to create a droplist/listbox DOM element *within* the document. Of course, the <<select>> macro isn't a javascript function, so it can't be used in place of any of the browser-supplied functions described above to simply return a selected value. However, the following *might* produce a suitable result for the "pick a username from a list" functionality, even if it can't be easily generalized for other uses. Using http://www.TiddlyTools.com/#ShowPopup and http://www.TiddlyTools.com/#StickyPopupPlugin give this a try... create a tiddler called [[SelectUsername]] containing: <<tiddler ShowPopup with: SelectUsername##dialogbox "select username..." "choose a username from a list" button auto NOTsticky>>/% !dialogbox <<select =txtUserName autosave +SelectUsernameList>> !end %/ enjoy, -e Eric Shulman TiddlyTools / ELS Design Studios --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "TiddlyWiki" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/tiddlywiki?hl=en -~----------~----~----~----~------~----~------~--~---

