Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » scout » How can i retrieve a byte[] field from database?
icon3.gif  How can i retrieve a byte[] field from database? [message #1759732] Mon, 17 April 2017 19:43
marco santos is currently offline marco santosFriend
Messages: 9
Registered: March 2017
Junior Member
Hello,

I am working with jasper reports on scout, i successfully generated a report and saved on a database, but now i need to show the pdf in the proper TablePage
I tried this:
@Order(2000)
		public class FileColumn extends AbstractColumn<byte[]> {
			
			@Override
			protected String getConfiguredHeaderText() {
				return TEXTS.get("File");
			}
			
			@Override
			protected boolean getConfiguredHtmlEnabled() {
				return true;
			}

			@Override
			protected int getConfiguredWidth() {
				return 100;
			}

			@Override
			protected boolean getConfiguredVisible() {
				return true;
			}

			@Override
		      protected void execDecorateCell(Cell cell, ITableRow row) {
		        StringBuilder linkBuilder = new StringBuilder();
		        linkBuilder.append(getLinkDocumentColumn().getValue(row));
		        String encodedHtml = HTML.link(linkBuilder, TEXTS.get("Open")).addAttribute("target", "_blank").toHtml();
		        cell.setHtmlEnabled(true);
		        cell.setText(encodedHtml);
		      }
		}


But didn't work, does anyone knows how to do it?
Previous Topic:Exception in thread "main" java.lang.NoClassDefFoundError:
Next Topic:Eclipse neon error
Goto Forum:
  


Current Time: Mon Sep 25 18:45:59 GMT 2017

Powered by FUDForum. Page generated in 0.02921 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software