Examples of ReportFormattingException


Examples of com.haulmont.yarg.exception.ReportFormattingException

    protected byte[] getContent(Object paramValue) {
        try {
            return IOUtils.toByteArray(new URL(paramValue.toString()).openStream());
        } catch (IOException e) {
            throw new ReportFormattingException("Unable to get image from " + paramValue, e);
        }
    }
View Full Code Here

Examples of com.haulmont.yarg.exception.ReportFormattingException


                putImage(worksheetPart, pkg, xlsxImage, image, anchor);
            }
        } catch (Exception e) {
            throw new ReportFormattingException("An error occurred while inserting bitmap to xlsx file", e);
        }
    }
View Full Code Here

Examples of com.haulmont.yarg.exception.ReportFormattingException

                run.getContent().add(drawing);
                drawing.getAnchorOrInline().add(inline);
                text.setValue("");
            }
        } catch (Exception e) {
            throw new ReportFormattingException("An error occurred while inserting bitmap to docx file", e);
        }
    }
View Full Code Here

Examples of com.haulmont.yarg.exception.ReportFormattingException

                Dimension imageDimension = picture.getImageDimension();
                double actualHeight = imageDimension.getHeight();
                picture.resize((double) image.height / actualHeight);
            }
        } catch (IllegalArgumentException e) {
            throw new ReportFormattingException("An error occurred while inserting bitmap to xls file", e);
        }
    }
View Full Code Here

Examples of com.haulmont.yarg.exception.ReportFormattingException

                    XComponent xComponent = officeComponent.getOfficeComponent();
                    insertImage(xComponent, officeComponent.getOfficeResourceProvider(), destination, textRange, image);
                }
            }
        } catch (Exception e) {
            throw new ReportFormattingException("An error occurred while inserting bitmap to doc file", e);
        }
    }
View Full Code Here

Examples of com.haulmont.yarg.exception.ReportFormattingException

            }

            if (!inserted)
                destination.getText().insertString(textRange, "", true);
        } catch (Exception e) {
            throw new ReportFormattingException("An error occurred while inserting html to doc file", e);
        }
    }
View Full Code Here

Examples of com.haulmont.yarg.exception.ReportFormattingException

            R run = (R) text.getParent();
            run.getContent().add(ac);
            text.setValue("");
            wordPackage.getContentTypeManager().addDefaultContentType("html", "text/html");
        } catch (Exception e) {
            throw new ReportFormattingException("An error occurred while inserting html to docx file", e);
        }
    }
View Full Code Here

Examples of com.haulmont.yarg.exception.ReportFormattingException

                if (pattern.matcher(templateText).find()) {
                    return xText;
                }
            }
        } catch (Exception e) {
            throw new ReportFormattingException(e);
        }
        return null;
    }
View Full Code Here

Examples of com.haulmont.yarg.exception.ReportFormattingException

    public XComponent loadXComponent(InputStream inputStream) throws com.sun.star.lang.IllegalArgumentException, IOException {
        try {
            return loadXComponent(IOUtils.toByteArray(inputStream));
        } catch (java.io.IOException e) {
            throw new ReportFormattingException("An error occurred while reading bytes", e);
        }
    }
View Full Code Here

Examples of com.haulmont.yarg.exception.ReportFormattingException

            tempFile.deleteOnExit();

            FileUtils.writeByteArrayToFile(tempFile, bytes);
            return tempFile;
        } catch (java.io.IOException e) {
            throw new ReportFormattingException("Could not create temporary file for pdf conversion", e);
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.