no proglist record avail

jmac12

Member
a customer of mine is saying they are getting a error on this program thats says no proglist record is avail. But looking in the code can only see this place where proglist is used bar for the buffer and a like on a temp table just wondered if anyone had any ideas?
bProgList is a buffer for proglist. cheers

for each proglist where
proglist.lupd-time > 0
no-lock:

process events.

if progList.prog-prefix = "":u and can-find(first bProgList where
bProgList.prog-no = progList.prog-no and
bProgList.prog-prefix > "":u) then
next.

if not progList.prog-prefix begins "GUI":u and can-find(first bProgList where
bProgList.prog-no = progList.prog-no and
bProgList.prog-prefix begins "GUI":u) then
next.

for each uuser
no-lock:

process events.

if uuser.system or uuser.cdm-user then
do:
create ttUsersSensitiveProgs.
assign ttUsersSensitiveProgs.t-uu-inits = uuser.uu-inits
ttUsersSensitiveProgs.t-prog-desc = proglist.prog-desc.
end.
else
do:
chrProgNo = lc(progList.prog-no).

find uProgHdr where
uProgHdr.compno = 0 and
uProgHdr.uu-inits = uuser.uu-inits and
uProgHdr.prog-no = chrProgNo
use-index key
no-lock no-error.

if available uproghdr and uproghdr.permit then
do:
create ttUsersSensitiveProgs.
assign ttUsersSensitiveProgs.t-uu-inits = uproghdr.uu-inits
ttUsersSensitiveProgs.t-prog-desc = proglist.prog-desc.
end.
end.
end.
end.
 
a customer of mine is saying they are getting a error on this program thats says no proglist record is avail. But looking in the code can only see this place where proglist is used bar for the buffer and a like on a temp table just wondered if anyone had any ideas?
bProgList is a buffer for proglist. cheers

You should use CODE tages when you post code. It makes it readable ;)

Code:
for each proglist where        
    proglist.lupd-time > 0        
    no-lock:                
                
    process events.       
       
    if progList.prog-prefix = "":u and can-find(first bProgList where       
                                                bProgList.prog-no       =   progList.prog-no    and       
                                                bProgList.prog-prefix   >   "":u)   then       
        next.       
           
    if not progList.prog-prefix begins "GUI":u and can-find(first bProgList where       
                                                            bProgList.prog-no       =   progList.prog-no    and       
                                                            bProgList.prog-prefix   begins   "GUI":u)   then       
        next.       
       
    for each uuser       
        no-lock:       
           
        process events.       
       
        if uuser.system or uuser.cdm-user then       
        do:       
            create ttUsersSensitiveProgs.                
            assign ttUsersSensitiveProgs.t-uu-inits    = uuser.uu-inits                
                   ttUsersSensitiveProgs.t-prog-desc   = proglist.prog-desc.          
        end.       
        else       
        do:       
            chrProgNo    =   lc(progList.prog-no).               
               
            find uProgHdr where                  
                 uProgHdr.compno    =   0               and                  
                 uProgHdr.uu-inits  =   uuser.uu-inits  and                  
                 uProgHdr.prog-no   =   chrProgNo                  
                 use-index key                  
                 no-lock no-error.              
       
            if available uproghdr and uproghdr.permit then       
            do:       
                create ttUsersSensitiveProgs.                
                assign  ttUsersSensitiveProgs.t-uu-inits    = uproghdr.uu-inits                
                        ttUsersSensitiveProgs.t-prog-desc   = proglist.prog-desc.                
            end.       
        end.       
    end.                
end.

My thoughts are that 1) this isn't all of the code and 2) what version of Progress is this? If it is modern you could use a try/catch block to find out where the error is really ocurring.
 
its 10.2b I thought about doing a try and catch but wasnt srue how that would show where its happening. doesnt seem to happen all the time. an another question how do i do that code tag thing?
 
realised that it must be coming from another program im running something strange in way i call otherprograms i make the currrent window = to the new program so that means the error message is most likely coming from somewhere else... oh joy
 
Back
Top