Jump to content
Fivewin Brasil

gilmer

Administrador
  • Posts

    3,036
  • Joined

  • Last visited

  • Days Won

    34

Posts posted by gilmer

  1.  

    Amigos, o gilmer me deu uma luz.

    Assim funciona, porem demora muito se o HD estiver com muita coisa instalada

    
    function ProcuraArquivo()
     
       local aFiles := aFindFile( "ValidadorSintegra2017.exe", "c:" )
       local n
    
       for n := 1 to Len( aFiles )
          MsgInfo( aFiles[ n ] )
       next
    return nil
    //---------------------------------------------------------------------------//
    function aFindFile( cFileName, cPath, aResult )
    
       local aFiles := Directory( cPath + "\", "D" )
       local n
       Logfile("log.txt",{"FileName=",cFileName})
    
       //If cPath=="c:"
       //   xBrowse(aFiles)
       //Endif
    
       if ProcName( 5 ) == "AFINDFILE"
          return nil
       endif
    
       if aResult == nil
          aResult = {}
       endif
       //? cPath
       logfile("log.txt",{"Path:",cPath})
       //xBrowse(aFiles)
       for n = 1 to Len( aFiles )
          SysRefresh()
          logfile("log.txt",{Upper( aFiles[ n ][ 1 ] ) == Upper( cFileName ),Upper( aFiles[ n ][ 1 ] )+"="+Upper( cFileName )})
          if Upper( aFiles[ n ][ 1 ] ) == Upper( cFileName )
             AAdd( aResult, cPath + "\" + cFileName )
          endif
          if "D" $ aFiles[ n ][ 5 ]  .and. ! ( aFiles[ n ][ 1 ] $ ".." )
             aFindFile( cFileName, cPath + "\" + aFiles[ n ][ 1 ], aResult )
          endif
       next
    
    return aResult
    

    Obrigado a todos

    Não esquece de tirar os logfile, isto deixara muito mais lento.

     

     

  2. Bom Dia,

    Segue o mesmo padrão, porem, não pode ser xharbour, tem que ser harbour e todas as libs que você usar tem que ser 64 bits, não poderá usar nenhuma lib 32 bits.

    Extensão .a é do linux ou compiladores multiplataforma vindo do linux

     

     

     

     

  3. Modificações:

    METHOD StruCartao(oItem) CLASS TVoNFe2G
       local axArray := {}
       aadd(axArray, {"tpIntegra", TVoNFeItem():New("N", 0, 1, ,,,oItem:tpIntegra_Opc )  }  )
       aadd(axArray, {"CNPJ"  , TVoNFeItem():New("C", 0, 1, 14,,,oItem:CNPJ_Opc )  }  )
       aadd(axArray, {"tBand" , TVoNFeItem():New("C", 0, 1, 02,,,oItem:tBand_Opc )  }  )
       aadd(axArray, {"cAut"  , TVoNFeItem():New("C", 0, 1 ,20,,,oItem:cAut_Opc )  }  )

    return( axArray )
     

    CLASS TVoNFePag
       DATA tPag
       DATA vPag
       DATA tpIntegra_Opc
       DATA CNPJ_Opc
       DATA tBand_Opc
       DAtA cAut_Opc

    ENDCLASS
     

     

     

×
×
  • Create New...