graemeaustin Posted October 18, 2001 Posted October 18, 2001 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
Anatoli Posted October 18, 2001 Posted October 18, 2001 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.
graemeaustin Posted October 19, 2001 Author Posted October 19, 2001 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
Garry Claridge Posted November 8, 2001 Posted November 8, 2001 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 ]
Simon Posted November 9, 2001 Posted November 9, 2001 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
Recommended Posts
This topic is 8752 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now