Árvore de páginas

Versões comparadas

Chave

  • Esta linha foi adicionada.
  • Esta linha foi removida.
  • A formatação mudou.

...

Bloco de código
languagecpp
firstline1
titletoJsonFile fromJsonFile
linenumberstrue
# include tlpp-core.th

function u_capturaJsonFile()

local cPathAndFile 	:= 'C:\tlppcore\fromjsonfile.txt'
local oJsonObject  	:= JSONObject():New()
local xReturn		:= Nil

xReturn := oJsonObject:fromJsonFile(cPathAndFile)

if valType(xReturn) == "U"
	conout("Arquivo: "+cPathAndFile+" lido com sucesso")
else
	conout("Erro: "+cValToChar(xReturn)+" na leitura do arquivo: "+cPathAndFile)
endif

freeObj(oJsonObject)

return

...