October 18, 200124 yr I keep coming up against the same problem and cannot find any answers in the forum ... yet. Suppose I have a CDML page which is using data from file A. Inside the page I run an inlineaction pointing at fileB. What i want to do is take different actions to fileA based on the search results in fileB, thus: blah fileA blah [fmp-inlineaction: -db=fileB, -recID=5, -find] [fmp-if: <test condition like currentfoundcount.eq.0>] do something to file A eg edit currentrecid [fmp-else] do something else to file A eg edit another record [/fmp-if] [/fmp-inlineaction] The problem I have is that the currentrecID inside the inlineaction tag refers to the current record in fileB and once the end inlineaction tag appears I cannot see the currentfoundcount from inside it. Any bright ideas from the clever folk out there??? Graeme
October 18, 200124 yr Think about all Inlines as completely separated from page flow: 1 2 3 Inline 1 Inline 2 Inline 3 Inline 4 Inline 5 4 5 6 You can try to store something in Token variables, but I doubt the result can be used on the same page.
October 19, 200124 yr Author I've tried tokens, I've tried cookies but nothing has worked. Judging from what you are saying, I am trying to take inlineactions into a place that they do not belong. So back to a load of calculation fields and convoluted fmp-if statements. Thanks for letting me know that I should not waste any more time trying to find a workaround. Graeme
November 8, 200124 yr As an alternative, you may be able to assign RecordId's to a Javascript variable/array. Then reuse them within the InLine. This is for "post-processing" the results. Not as part of the one pass through WebCompanion. Disregard this post, I'm having one of those mornings! I may have to go up town for a camomile with the hippies. All the best. Garry [ November 08, 2001: Message edited by: garrycl ]
November 9, 200124 yr To get the use of the file a currentrecid inside an inline you do the follwoing. [fmp-inlineaction: -db=mydatabase.fp5, token.1="{currentrecid}", fieldtosearch="valuetofind", -find] If you want to pull information from file a into your found results to show different info you use the { } tags. ie you have a field in file a that you want to use as an if statement(on my site a candidate says he is interested in consulting. I find his record and then on my page I do a search of the company database and of the info found I want to show the consulting departments phone number as that is what the guy is interested in) ou have to use tokens and the { } tags in the inline. Therefore unfortunately limiting yourselve to 10 fields you can use. [fmp-inlineaction: -db=companydatabase.fp5, industry="{fmp-field: industry}", -token.1=(fmp-field: industry}", -find][fmp-record][fmp-if: currrenttoken:1.eq.consulting][fmp-field: consulting_phone_number][/fmp-if][/fmp-record][/fmp-inlineaction] Hope that helps
Create an account or sign in to comment