The -Random command tag returns a random record from a FileMaker Pro database.
The database and table for the random action should be specified using the -Database and -Table command tags.
[Inline: -Random,
-Database='Database_Name',
-Table='Table_Name', ...]
<a href="default.lasso?-Random&
-Database=Database_Name&
-Table=Table_Name&...">Link</a>
<form action="default.lasso" method="POST">
<input type="hidden" name="-Random" value="">
<input type="hidden" name="-Database" value="Database_Name">
<input type="hidden" name="-Table" value="Table_Name">
...
<input type="submit" name="-Random" value="Random Record">
</form>
Use an [Inline] tag with a -Random command tag. The following example finds a random record from within the Contacts.fp3 database. The -MaxRecords parameter is set to 1 in order to return 1 record from the database.
[Inline: -Random,
-Database='Contacts.fp3',
-Table='People',
-MaxRecords=1]
[Records]
<br>[Field: 'First_Name'] [Field: 'Last_Name']
[/Records]
[/Inline]
<br>Mark Surname
Tag Link | -Random | Category | Action |
---|---|---|---|
Type | Command | Data Source | FMP |
Support | Preferred | Version | 3.0 |
Output Type | None | Security | Database,Classic |
Implementation | LCAPI | Sets | Lasso 8.5, Lasso 8.0, Lasso 7.0, Lasso 6.0, Lasso 5.0,LDML3x |
Please note that periodically LassoSoft will go through the notes and may incorporate information from them into the documentation. Any submission here gives LassoSoft a non-exclusive license and will be made available in various formats to the Lasso community.
©LassoSoft Inc 2015 | Web Development by Treefrog Inc | Privacy | Legal terms and Shipping | Contact LassoSoft