Function CallMe (part of our standard procedure) >Parameter tcEmpno >Local lnDS, lnNewDS, lcCallMe > ><b>lnDS = set('datasession') >lnNewDS = createobject('session') >set datasession to lnNewDS.datasessionid</b> > >select 0 >use people order empno >seek tcEmpno >if found() > lcCallMe=iif(empty(termdate),'','*')+trim(callname)+' '+empname >else > lcCallMe='' >endif > ><b>release lnNewDS >set datasession to (lnDS)</b> > >return lcCallMeIn addition to what the others have told you, you should not release the object reference while you are still in the DS of that object. You should release lnNewDS after you change back to the original DS. Otherwise, this could leave a dangling reference and not really close the DS [shown as UNKNOWN if viewed in the Session form].