FORUMS PROFESSIONNELS
WINDEV
,
WEBDEV
et
WINDEV Mobile
Accueil
|
Messages récents
|
Connexion
|
Déconnexion
|
Français
Accueil
→
WINDEV 25
→
windev 21 - relatório com formatação condicional
windev 21 - relatório com formatação condicional
Débuté par Mister ANDRE MARTINI, 13 oct. 2016 18:54 - 3 réponses
Connectez-vous…
Mister ANDRE MARTINI
#1
Membre enregistré
212 messages
Popularité : +25 (25 votes)
Posté le 13 octobre 2016 - 18:54
Pessoal,
como faço para colocar uma condição num relatório, quando for pessoa física imprime o CPF e não imprime o CNPJ e quando for pessoal jurídica imprime o CNPJ e não imprime o CPF (são campos diferentes na base de dados)?
No crystal reports em uma opção "Suprimir Se", se a condição for verdadeira não imprime e se for falso imprime.
--
André Martini
IS2 Automotive
http://www.is2.inf.br/is2automotive/index.html
IS2 Construtive
http://www.is2.inf.br/is2construtive/index.html
IS2 Store
http://www.is2.inf.br/is2store/index.html
IS2 Gerent
http://www.is2.inf.br/is2gerent/index.html
Signaler
0
0
Mister ANDRE MARTINI
#2
Membre enregistré
212 messages
Popularité : +25 (25 votes)
Posté le 18 octobre 2016 - 14:42
Consegui resolver ...
reading the
Data
RPT_
IF MySource
.
Tipo_pessoa
=
"JURÍDICA"
THEN
STC_
Cnpj_cliente
..
Caption
=
"CNPJ"
ITEM_
Cnpj
..
Visible
=
True
ELSE
STC_
Cnpj_cliente
..
Caption
=
"CPF"
ITEM_
Cnpj
..
Visible
=
False
END
Windev 21 - Relatório Suprimir Campo
--
André Martini
IS2 Automotive
http://www.is2.inf.br/is2automotive/index.html
IS2 Construtive
http://www.is2.inf.br/is2construtive/index.html
IS2 Store
http://www.is2.inf.br/is2store/index.html
IS2 Gerent
http://www.is2.inf.br/is2gerent/index.html
Signaler
0
0
Mister ANDRE MARTINI
#3
Membre enregistré
212 messages
Popularité : +25 (25 votes)
Posté le 18 octobre 2016 - 14:43
existe também a opção de mudar o conteúdo de um item do relatório (1 item para duas informações)
IF MySource
.
Tipo_pessoa
=
"JURÍDICA"
THEN
STC_
Cnpj_cliente
..
Caption
=
"CNPJ"
ITEM_
Cnpj
..
DisplayedItem
=
"Cnpj"
ELSE
STC_
Cnpj_cliente
..
Caption
=
"CPF"
ITEM_
Cnpj
..
DisplayedItem
=
"Cpf"
END
--
André Martini
IS2 Automotive
http://www.is2.inf.br/is2automotive/index.html
IS2 Construtive
http://www.is2.inf.br/is2construtive/index.html
IS2 Store
http://www.is2.inf.br/is2store/index.html
IS2 Gerent
http://www.is2.inf.br/is2gerent/index.html
Signaler
0
0
Mister ANDRE MARTINI
#4
Membre enregistré
212 messages
Popularité : +25 (25 votes)
Posté le 19 octobre 2016 - 21:31
só uma correção, não é a propriedade DisplayedItem, veja o código abaixo para mudar a informação de um item do relatório
IF MySource
.
Descricao_alternativa
<
>
""
THEN
ITEM_
Descricao_do_produto
=
MySource
.
Descricao_alternativa
// imprime a descrição alternativa
ELSE
IF MySource
.
Codigo_do_produto
>
0
THEN
ITEM_
Descricao_do_produto
=
MySource
.
Descricao_do_produto
// imprime a descrição do produto
ELSE
//serviço
ITEM_
Descricao_do_produto
=
MySource
.
Descricao_do_servico
// imprime a descrição do serviço
END
END
--
André Martini
IS2 Automotive
http://www.is2.inf.br/is2automotive/index.html
IS2 Construtive
http://www.is2.inf.br/is2construtive/index.html
IS2 Store
http://www.is2.inf.br/is2store/index.html
IS2 Gerent
http://www.is2.inf.br/is2gerent/index.html
Signaler
0
0
→ Revenir à WINDEV 25
WINDEV 25
Français
English
Español
Portuguesa
Fermer cette fenêtre
Type de recherche
Uniquement les sujets
Tous les messages
Période de recherche
Date indifférente
Moins d'une heure
Moins de 24 heures
Moins d'une semaine
Moins d'un mois
Moins d'un an
Annuler
Aperçu de votre message
Ajouter une image
Importer une image depuis une URL
Envoyer une image depuis un fichier de votre disque
Déposez ici un fichier ou cliquez sur "Parcourir..."
ou
Annuler
0%
WLangage
SQL
XML, HTML
JAVA, Javascript
Texte