Visualizzazione dei risultati da 1 a 4 su 4
  1. #1
    Utente di HTML.it
    Registrato dal
    Jan 2015
    residenza
    napoli
    Messaggi
    65

    ireport the document has no pages

    ragazzi quando creo l'anteprima del mio report mi esce the document has no pages
    ma come è possibile ????

  2. #2
    posta del codice così magari riusciamo a capire l'ambito, non abbiamo mica la sfera di cristallo...
    Ultima modifica di schumy2000; 08-04-2016 a 10:14
    I computer sono incredibilmente veloci, accurati e stupidi.
    Gli uomini sono incredibilmente lenti, inaccurati e intelligenti.
    Insieme sono una potenza che supera l'immaginazione.

    A.Einstein

  3. #3
    Utente di HTML.it
    Registrato dal
    Jan 2015
    residenza
    napoli
    Messaggi
    65
    codice HTML:
    <?xml version="1.0" encoding="UTF-8"?><jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="preventivo" language="groovy" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="8e01f330-840d-40aa-9395-85b7f1d876cc">	<property name="ireport.zoom" value="1.0"/>	<property name="ireport.x" value="0"/>	<property name="ireport.y" value="0"/>	<parameter name="NOME" class="java.lang.String"/>	<background>		<band splitType="Stretch"/>	</background>	<title>		<band height="58" splitType="Stretch">			<staticText>				<reportElement x="135" y="10" width="271" height="48" uuid="0dac8bc1-8ef9-4781-977e-3a18a2ebd21c"/>				<textElement>					<font size="24"/>				</textElement>				<text><![CDATA[Scheda di lavoro]]></text>			</staticText>		</band>	</title>	<pageHeader>		<band height="91" splitType="Stretch">			<staticText>				<reportElement x="30" y="18" width="100" height="20" uuid="013bd54f-db26-425c-9fc6-725e4143cc90"/>				<text><![CDATA[nome ]]></text>			</staticText>			<textField>				<reportElement x="135" y="18" width="100" height="20" uuid="ac3a8be7-c10d-468e-aeae-e785443e4285"/>				<textFieldExpression><![CDATA[$P{NOME}]]></textFieldExpression>			</textField>		</band>	</pageHeader>	<columnHeader>		<band height="61" splitType="Stretch"/>	</columnHeader>	<detail>		<band height="125" splitType="Stretch"/>	</detail>	<columnFooter>		<band height="45" splitType="Stretch"/>	</columnFooter>	<pageFooter>		<band height="54" splitType="Stretch"/>	</pageFooter>	<summary>		<band height="42" splitType="Stretch"/>	</summary></jasperReport>
    questo è il codice del report in pratica ci sta un label con scritto nome : $P{NOME} con questo parametro .

    questo è il codice che uso per richiamare il report

    codice:
            HashMap hm = null;
            Map params = new HashMap();
            hm = new HashMap();
            hm.put("NOME", "123");
                String report = "C:\\Users\\Danilo\\Desktop\\preventivo.jrxml";
                JasperReport jasp_report = JasperCompileManager.compileReport(report);
                JasperPrint jasp_print = JasperFillManager.fillReport(jasp_report, hm);
                JasperViewer.viewReport(jasp_print);

  4. #4
    Utente di HTML.it
    Registrato dal
    Jan 2015
    residenza
    napoli
    Messaggi
    65
    ok risolto era un problema di connessione al mio database grazie

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.