Jump to content
Fivewin Brasil

Dll externa


SISCO

Recommended Posts

   xDll := LoadLibrary("arquivo.dll")

   iRetorno := Autentica(cnpj,pdv,chaveAutenticacao)

   if iRetorno # 0
      MsgAlert("Não foi possível autenticar ","Atenção")
      return
    Endif
 

//--------------------------------------------------------------------
Function Autentica(cnpj,pdv,chaveAutenticacao)

Return DllCall( xDll, 32, "Autenticar","cnpj,pdv,chaveAutenticacao")
 

Link to comment
Share on other sites

Estou tentado fazer a integração com cappta, este é o modelo em .net

 

using System;
using Cappta.Gp.Api.Com;

namespace CappAPIIntegration

{
    class Program
    {
        static void Main(string[] args)
        {
            ClienteCappta cappta = new ClienteCappta();

            string cnpj = "00000000000000";
            int pdv = 8;
            string chaveAutenticacao = "2C1CE88C6A0C4FA6BF2D519B1DB31DF4";

            int resultadoAutenticacao = cappta.AutenticarPdv(cnpj, pdv, chaveAutenticacao);
            if (resultadoAutenticacao != 0)
            {
                Console.WriteLine("Não foi possível autenticar com o CapptaGpPlus");
                return;
            }
        }
    }
}
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...