Função: X1Pergunt - Descrição da pergunta
Versões: | Advanced Protheus 5.07 , Advanced Protheus 5.08 , Advanced Protheus 6.09 , Advanced Protheus 7.10 , Microsiga Protheus 8.11 , Protheus 10 |
Compatível Países: | Todos |
Sistemas Operacionais: | Todos |
Compatível às Bases de Dados: | Todos |
Nível de Acesso: | Nível 1 (Acesso Clientes) |
Idiomas: | Espanhol , Inglês |
Descrição:
A função X1Pergunt() retorna descrição de uma pergunta contida no dicionário de dados SX1, de acordo com o registro posicionado no SX1 e o idioma corrente.
Programa Fonte:
AP5TRANSLATE.PRW
Sintaxe:
X1Pergunt - Descrição da pergunta ( ) --> cRet
Retorno:
-
cRet(caracter)
- Descrição da pergunta
Exemplos
#include "protheus.ch"User Function TestX1Perg()Local cFile Local oDlg Local cRetLocal oPanel1, oPanel2Local oGet, cGet := Space(6)Local oSay1Local oLbxLocal aDesc := {} Aadd(aDesc, {"", ""})DEFINE MSDIALOG oDlg TITLE "Teste X1Pergunt" From 000,0 TO 200,300 PIXELoDlg:lMaximized := .T.@ 000, 000 MSPANEL oPanel1 SIZE 10, 30 OF oDlg oPanel1:align:= CONTROL_ALIGN_TOP @ 12, 05 SAY oSay1 VAR "Pergunta: " OF oPanel1 PIXEL @ 12, 30 GET oGet VAR cGet OF oPanel1 SIZE 100,009 PIXEL oGet:bLostFocus := {|| ProcuraDesc(@aDesc, Upper(AllTrim(cGet)), @oLbx) } @ 12, 140 BUTTON "Fechar" PIXEL SIZE 40,12 OF oPanel1 ACTION oDlg:End()@ 000, 000 MSPANEL oPanel2 SIZE 10, 90 OF oDlg oPanel2:align:= CONTROL_ALIGN_ALLCLIENT @ 30,05 LISTBOX oLbx FIELDS HEADER "Ordem", "Descrição" SIZE 30, 150 OF oPanel2 PIXEL oLbx:SetArray(aDesc) oLbx:bLine := {|| {aDesc[oLbx:nAt,1],aDesc[oLbx:nAt,2]}} oLbx:align:= CONTROL_ALIGN_ALLCLIENT ACTIVATE MSDIALOG oDlg CENTEREDReturn User Function ProcuraDesc(aDesc, cGet, oLbx)aDesc := {}DbSelectArea("SX1")DbSeek(cGet)While !Eof() .and. x1_grupo == cGet Aadd( aDesc, {X1_ORDEM, X1Pergunt()}) dbSkip()End oLbx:SetArray(aDesc) oLbx:bLine := { || {aDesc[oLbx:nAt,1],aDesc[oLbx:nAt,2]}}oLbx:Refresh()Return
Visão Geral
Import HTML Content
Conteúdo das Ferramentas
Tarefas