[RESOLVIDO] Problema ao criar folder via upc

Discussão em 'EMS , HCM e Totvs 11' iniciado por erickles, Dezembro 29, 2009.

Status do Tópico:
Não esta aberto para novas mensagens.
  1. erickles

    erickles Membro Participativo

    Olá Pessoal,

    Estou tentando criar uma folder no programa cc0300a, que é um subprograma do cc0300, mas esta tando a mensagem de erro em anexo..

    Alguem saberia como solucionar?

    Arquivos Anexados:

  2. af.dums

    af.dums Membro Ativo

    Opa...

    Tem como postar o fonte da tua UPC?

    Obrigado.
  3. erickles

    erickles Membro Participativo

    Entao, to usando o codigo abaixo:

    Código:
    {utp/ut-glob.i}
    
    def input param p-ind-event  as char          no-undo.
    def input param p-ind-object as char          no-undo.
    def input param p-wgh-object as handle        no-undo.
    def input param p-wgh-frame  as widget-handle no-undo.
    def input param p-cod-table  as char          no-undo.
    def input param p-row-table  as rowid         no-undo.
    
    
    def new global shared var adm-broker-hdl  as handle   no-undo.
    def new global shared var h_folder_upc    as handle   no-undo.
    def new global shared var h_viewer_upc    as handle   no-undo.
    
    def var h_object             as handle        no-undo.
    def var c-objects            as char          no-undo.
    def var c-folder             as char          no-undo.
    def var i-objects            as int           no-undo.
    DEF VAR l-record             AS LOG           NO-UNDO.
    DEF VAR l-group-assign       AS LOG           NO-UNDO.
    
    if  p-ind-event   = "INITIALIZE" and
        p-ind-object  = "CONTAINER"   then do:
    
    
        run get-link-handle in adm-broker-hdl (input  p-wgh-object ,
                                               input "PAGE-SOURCE" ,
                                               output c-folder).
        assign h_folder_upc = widget-handle(c-folder) no-error.
        if  valid-handle(h_folder_upc) then do:
            run create-folder-page  in h_folder_upc (input 7              ,
                                                     input "Inf l").
            run create-folder-label in h_folder_upc (input 7              ,
                                                     input "Inf Compl").
            run select-page in p-wgh-object (input 7).
            run init-object in p-wgh-object (input "view/v01cd0704.w",
                                             input  p-wgh-frame          ,
                                             input "Layout = "           ,
                                             output h_viewer_upc        ).
            run set-position in h_viewer_upc (input 7,
                                              input 3.86).
            run get-link-handle in adm-broker-hdl (input  p-wgh-object     ,
                                                   input "CONTAINER-TARGET",
                                                   output c-objects       ).
            do  i-objects = 1 to num-entries(c-objects):
    
                assign h_object = widget-handle(entry(i-objects,c-objects)).
                if index(h_object:FILE-NAME, "adqry/q05ad098.w") <> 0 and
                   not l-record then do:
                   assign l-record = yes.
                   RUN add-link IN adm-broker-hdl (INPUT h_object,
                                                   INPUT "Record":U,
                                                   INPUT h_viewer_upc).
                end.
                if index(h_object:FILE-NAME, "cdp/cd0704-v01.w") <> 0 and
                   not l-group-assign then do:
                   assign l-group-assign = yes.
                   RUN add-link IN adm-broker-hdl (INPUT h_object,
                                                   INPUT "Group-Assign":U,
                                                   INPUT h_viewer_upc).
                end.
            end.
    
            RUN dispatch IN h_viewer_upc ("initialize":U).
    
            /*run select-page in p-wgh-object (input 1).*/
    
        end.
        
    end.
    
    
    Pelo que note, esta dando problema na procedure "get-link-handle "...
Status do Tópico:
Não esta aberto para novas mensagens.

Compartilhe esta Página