May 6, 200421 yr Hi - I've got a reporting system with a "filter" at the top of the page, to narrow the search results (via inline action). The question I have is: once the results are displayed, if more exist than will fit on one page, the [FMP-linkprevious] and [FMP-linknext] don't behave properly. I'm wondering about the placement of these 'previous/next' links within the InlineAction tag pair. Interestingly the 'rangestart' and 'rangeend' and 'rangesize' seem to show correct numbers. Here's a code snippet: Thanks in advance. <P>[FMP-linkFirst]First[/FMP-LinkFirst] [FMP-LinkLast]Last[/FMP-LinkLast] [FMP-InlineAction: -db=coursesByUser.fp5, -lay=Search, -token.0={CurrentRecID}, -sortfield={CurrentToken:1}, -sortorder={CurrentToken:2}, course_number="{CurrentToken:3}", course_name="{CurrentToken:4}", first_name="{CurrentToken:5}", last_name="{CurrentToken:6}", dept="{CurrentToken:7}", ds_prs_id="{CurrentToken:8}", -max="{CurrentMax}", -find] <BR> <P>Displaying records [FMP-rangestart] through [FMP-rangeend] of [FMP-currentfoundcount] records found. ([FMP-rangesize] records displayed). <!-- the following does the sort stuff --> <TR BGCOLOR="#DCDCDC"><STRONG></TD> <TD>Course #</TD> <TD width=5></TD><TD><a href="javascript:doSort('course_name')">Course Name</a></TD> <TD width=5></TD><TD><a href="javascript:doSort('first_name')">First Name</a></TD> <TD width=5></TD><TD><a href="javascript:doSort('last_name')">Last Name</a></TD> <TD width=5></TD><TD><a href="javascript:doSort('actual_points')">Actual Pts</a></TD> <TD width=5></TD><TD><a href="javascript:doSort('poss_points')">Max Pts</a></TD> <TD width=5></TD><TD><a href="javascript:doSort('score')">%</a></TD> <TD width=5></TD><TD><a href="javascript:doSort('division')">Div</a></TD> <TD width=5></TD><TD><a href="javascript:doSort('dept')">Dept/Store</a></TD> <TD width=5></TD><TD><a href="javascript:doSort('course_finish_date')">Finish Date (GMT)</a></TD> <TD width=5></TD><TD>PRS_ID</TD></STRONG></FONT> </TR> [FMP-record] <TR> <TD>[FMP-course_number]</TD> <TD width=5></TD><TD>[FMP-field: course_name]</TD> <TD width=5></TD><TD>[FMP-field: first_name]</TD> <TD width=5></TD><TD>[FMP-field: last_name]</TD> <TD width=5></TD><TD>[FMP-field: actual_points]</TD> <TD width=5></TD><TD>[FMP-field: poss_points]</TD> <TD width=5></TD><TD>[FMP-field: score]</TD> <TD width=5></TD><TD>[FMP-field: division]</TD> <TD width=5></TD><TD>[FMP-field: dept]</TD> <TD width=5></TD><TD>[FMP-field: course_finish_date]</TD> <TD width=5></TD><TD>[FMP-field: ds_prs_id]</TD> </TR> </TD> [/FMP-record]<TD> </TD></TR> [/FMP-InlineAction] <P><FONT SIZE=+1>[FMP-linkprevious]Previous page.[/FMP-linkprevious]</FONT> <P><FONT SIZE=+1>[FMP-linknext]Next page.[/FMP-linknext]</FONT>
May 10, 200421 yr You may or may not find the demonstration "CDML Linking to the next record" in the Sample files forum useful.
May 12, 200421 yr Author Unable - thanks - I'm getting back on this query today, so I'll have a look!.
September 7, 200421 yr The [FMP-LinkPrevious] and [FMP-LinkNext] tags are outside the [FMP-InlineAction], while the [FMP-RangeStart] and [FMP-RangeEnd] tags are inside the [FMP-InlineAction]. That's why part of your code works, but the links do not. Unfortunately, just moving the link tags inside the [FMP-InlineAction] won't make them start working, because the InlineAction doesn't really have a notion of how to link to itself, because -- as an InlineAction, rather than a page/URL -- it's not a target. I can easily imagine ways to construct the appropriate information and pass it into the InlineAction via tokens, in a more capable language like PHP, but CDML is so limited, I'm not sure it's possible to do it. Possibly when combined with calculated FM fields... I've been struggling with this for a day now, and haven't found a solution. So if you got it working, please post here! (Note that Unable's example in the Samples forum does not use InlineAction anywhere, and so is not particularly helpful in this case.)
September 8, 200421 yr Well, I figured out how it should be possible to do this, but it depends on calculated fields in FileMaker to calculate -skip values to pass to the InlineAction via a token. However, because fields containing Status(CurrentRecordNumber) are not correctly evaluated by the Web Companion, this technique doesn't work. (See other thread for details.) If anyone wants me to explain the technique, in the hopes that FileMaker will fix the defect in Web Companion (given that the bug is nearly 4 years old, and FM6 is now obsolete, this seems unlikely), let me know...
September 8, 200421 yr I just did a quick test and found the solution Check the "Do not store calculation..." in the "Dfefine Fields - Storage Options". All the best. Garry
September 27, 200421 yr I just did a quick test and found the solution Check the "Do not store calculation..." in the "Dfefine Fields - Storage Options". As I wrote in another posting, actually, I know that you need to set any calculated fields that use Status() functions, esp. functions like Status(CurrentRecordNumber), to Unstored. All of my calculated fields in my testing were definitely set to Unstored, so that doesn't seem to have been the problem...
Create an account or sign in to comment