In addition to the usecache that you already have, here are my notes from when I had the same problem: (My complete notes are here: http://mineer.blogspot.com/search?q=spry+caching)
After that, you'll want to define a function callback that will be triggered *after* your server request to update the record: function UpdateRecordCallback(req) { // We just finished updating a record, force myDataSet to // reload the data from the server so our regions auto update. myDataSet.loadData(); } Then use the loadURL() utility function to send your request. You'll have to pass your callback function to loadURL so that it gets called when the request succeeds: function UpdateMyRecord(recordID) { Spry.Utils.loadURL("GET", "closetesrecord.php?id=" + recordID, true, UpdateRecordCallback); } I hope that helps. On 1/17/07, Chad McCue <[EMAIL PROTECTED]> wrote: > I created a search page that allows the admin to search for accounts in > the database. When they first come to the search screen all accounts in > the database are returned and presented to them. The xml document that > SPRY reads gets generated with all accounts in the DB. When the admin > conducts a search, I create a XML document only with the results > returned and then overwrite the original XML document. Works Perfectly. > The problem is the browser after the search is conducted still sees all > accounts even though the XML document only shows the results searched > for. Below is some code: > > I am running a cf component that returns a list of accounts and puts it > into and XML document like below. > > <CFQUERY> > SELECT BLAH > FROM BLAH > WHERE BLAH = BLAH > </CFQUERY> > > <CFXML VARIABLE="RecruitmentResults"> > <Recruitments> > <CFOUTPUT query="Recruitments" > > <Recruitment ID="#RecruitmentID#"> > <firstname>#htmleditformat(trim(FirstName))#</firstname> > <lastname>#htmleditformat(trim(LastName))#</lastname> > <company>#trim(CompanyName)#</company> > <country>#trim(Country)#</country> > <WantedPosition>#trim(WantedPosition)#</WantedPosition> > </Recruitment> > </CFOUTPUT> > </Recruitments> > </CFXML> > > <CFFILE ACTION="write" > FILE="#Request.XMLRoute#/Administrator_#Session.AdminID#/Recruitments.xm > l" OUTPUT="#ToString(RecruitmentResults)#" nameconflict="overwrite"> > > This is the part of my result page that is outputting the results. > > <!-- > var pageOffset = 0; > var pageSize = 50; > var pageStop = pageOffset + pageSize; > > <CFOUTPUT> > var dsRecruitments = new > Spry.Data.XMLDataSet("../DisplayPages/admin/Administrators/Administrator > _#Session.AdminID#/Recruitments.xml","Recruitments/Recruitment", { > filterFunc: MyPagingFunc }, {useCache:false}); > </CFOUTPUT> > > function MyPagingFunc(ds, row, rowNumber) > { > if (rowNumber < pageOffset || rowNumber >= pageStop) > return null; > return row; > } > > function UpdatePage(offset) > { > var numRows = dsRecruitments.getUnfilteredData().length; > > if (offset > (numRows - pageSize)) > offset = numRows - pageSize; > if (offset < 0) > offset = 0; > > pageOffset = offset; > pageStop = offset + pageSize; > > // Re-apply our non-destructive filter on dsStates1: > dsRecruitments.filter(MyPagingFunc); > > } > --> > </script> > > <div id="Recruitment_Div" spry:region="dsRecruitments"> > <table id="Recruitment_Table" class="datagrid" width="100%" > border="0" cellspacing="0" cellpadding="0"> > <tr class="FormBar"> > <th onclick="dsRecruitments.sort('lastname','toggle');" > align="left" class="LeftBorder" style="cursor:pointer"> Contact > Name</th> > <th onclick="dsRecruitments.sort('company','toggle');" > width="350" align="left" style="cursor:pointer">Company Name</th> > </tr> > <tbody> > <tr bgcolor="#Request.Row1Color#" spry:repeat="dsRecruitments" > class="FormBody2"> > <td width="125" align="left" valign="middle" class="LeftBorder"> > {firstname} {lastname} > </td> > <td width="350" valign="middle"> > {company} > </td> > </tr> > </tbody> > </table> > </div> > > > > > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Upgrade to Adobe ColdFusion MX7 Experience Flex 2 & MX7 integration & create powerful cross-platform RIAs http:http://ad.doubleclick.net/clk;56760587;14748456;a?http://www.adobe.com/products/coldfusion/flex2/?sdid=LVNU Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:266879 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4