Skip to content

Instantly share code, notes, and snippets.

@W1ll14nC4rl0s
Created May 16, 2018 19:40
Show Gist options
  • Save W1ll14nC4rl0s/11b38764401473df0a706edde8409229 to your computer and use it in GitHub Desktop.
Save W1ll14nC4rl0s/11b38764401473df0a706edde8409229 to your computer and use it in GitHub Desktop.
#include "protheus.ch"
#include "TbiConn.ch"
#include "TbiCode.ch"
#include "TopConn.ch
user function relint()
Local cDBOra := "MW_CLASSIC/MSSQL7" // alterar o alias/dsn para o banco/conexão que está utilizando
Local cSrvOra := "192.168.0.189" // alterar para o ip do DbAccess
nHwnd := TCLink(cDBOra, cSrvOra, 7890)
if nHwnd >= 0
Alert("Conectado")
endif
TCUnlink()
return
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment