home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.databases.paradox      To crash or not to crash, asks Borland      9,834 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 8,431 of 9,834   
   Kenneth to usenet@soleSPAMLESSassociates.com   
   Re: Unlocking problem...   
   09 Apr 07 09:32:48   
   
   From: usenet@soleSPAMLESSassociates.com   
      
   On Fri, 06 Apr 2007 11:23:18 -0400, Kenneth   
    wrote:   
      
   >On Wed, 04 Apr 2007 11:05:39 -0600, Liz McGuire   
   > wrote:   
   >   
   >   
   >Hi Liz, Jim, and all,   
   >   
   >It seems that I have this resolved...   
   >   
   >The form has a field (LastNameField) to which the cursor   
   >moves on opening.   
   >   
   >On the arrive of that field, I put:   
   >   
   >if not isEdit()   
   >   then   
   >      edit()   
   >		Viewed.value = today()   
   >		endedit()   
   >	else   
   >endif   
   >   
   >and all seems well.   
   >   
   >Sincere thanks, (and I'll be back if I find a hitch...)   
      
   Hi again,   
      
   Well, I am having a problem with this after all...   
      
   I have a field called "ModDate" that shows today() if there   
   is any modification to any field on the form.   
      
   I also have a field called "Viewed" that shows today() if a   
   record is viewed, whether or not anything is modified.   
      
   Of course, I would not want ModDate to change if there is no   
   modification to the record, but now, because of the change   
   to the "Viewed" field, ModDate also changes.   
      
   I assume that I can modify the "ModDate" code so that it   
   "ignores" changes to the "Viewed" field, but I don't know   
   how to do that.   
      
   Here is the ModDate code from the action event of the form:   
      
   method action(var eventInfo ActionEvent)   
      
   var   
   endVar   
   	if eventInfo.isPreFilter() then   
   		;// This code executes for each object on the form:   
    if isEdit() then   
   	if eventInfo.id() = DataRefresh then   
   	  eventInfo.setErrorCode(UserError)   
   	endIf   
    endIf   
   	else   
   		;//This code executes only for the form:   
      
   if  (eventInfo.id() = DataPostRecord   
     and  active.RecordStatus("New"))   
   or  (eventInfo.id() = DataUnlockRecord   
     and (active.RecordStatus("Modified")   
   or   active.RecordStatus("Locked"))) then	   
   	ModDate.value = today()   
   endIf   
   endIf   
   endMethod   
      
   Can you suggest the modification I need?   
      
   Sincere thanks,   
   --   
   Kenneth   
      
   If you email... Please remove the "SPAMLESS."   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca