Help need to embed jsp on flex
hi,
i m trying to build jsp application on flex, by keeping flex as the base. i want to navigate to jsp application for flex and i m using spring at the server side.
could any one help me on this. thnks in advance.
You can do it with code:
// set Stage properties
stage.align = StageAlign.TOP_LEFT;
stage.scaleMode = StageScaleMode.NO_SCALE;
// align movieclip
yourMovieClip.x = stage.stageWidth/2;
yourMovieClip.y = stage.stageHeight/2;
// or
yourMovieClip.x = stage.stageWidth/2 - yourMovieClip.width/2;
yourMovieClip.y = stage.stageHeight/2 - yourMovieClip.height/2;
Similar Messages
-
Help needed to take JSP content to hard copy
this is what i hav encounterd with..i hav text content in a jsp .that is to be printed in a in a pre printed paper,i only need to print some numbers and text in the page given infornt of the the fields printed in the page.can anyone giv a suggetion.i
hav no idea how to do it.plse help.thnaks in advance.This forum provides a spellchecker in the message editor toolbar. It might help a lot.
-
Urgent help needed in compiling JSP on websphere 6
we are migrating our app from websphere 5 to 6 version. our app has 2 JSP files. Jsp A and Jsp B...
Jsp A code
if(cond met) { <%@ include file = JspB %> }
Now JSP B code
<bean:define id='X' />
when i run the JSP A, it throws compilation error as below..
Jsp A failed to compile, variable X not resolved
An error occured in the statically included jsp B
The same code is running on websphere 5. its giving error on 6. ..Pls help..This is urgent,Could you post more details perhaps? Eg. the complete files.
Also, I would recommend that you consider using the runtime include, <jsp:include ...>, and put your variables in the request scope. -
Need help in writing a .jsp page
Hi Guys,
I am new to JSP. My requirement is " I have a link on my webpage. When the user clicks that link, a HTML page is displayed which has parameters to be entered (for ex: from_date , to_date). When the user clicks the submit button, a jsp page should be displayed in which a query is run to display the output. For example, the user enters the from_date and to_date parameter values to know the employees employed within those dates in their company. The query is "select empname,empno,sal,dept,comm from emp where employed_date between from_date and to_date" . The following should run and display in the jsp page.
How can i write a .jsp to extract the parameters that are entered in the HTML form in to a .jsp and run the query with those parameters to display the output. Help needed in making me write this .jsp for this query.
Help Aprreciated.
ThanksHm, your requirements sound like homework assignment from classroom. If so, is itn't better that you find the answer youself? There are plenty of very relevant references for how to use jsp to handle html forms or talk to a rdbms through a jdbc connection. For example, for jsp and html forms, you can google "jsp html forms"; for jsp and sql query, search for "jsp jdbc".
Tell me if this is not helpful. -
Help needed in calling a javascript function from a jsp
Hey guys,
I need help.
In my jsp I have a field called date. When i get date field from the database, it is a concatination of date and time field, so I wrote a small javascript function to strip just the date part from this date and time value.
The javascript function is
function formatDate(fieldName)
var timer=fieldName;
timer = timer.substring(5,7)+"/"+timer.substring(8,10)+"/"+timer.substring(0,4);
return timer;
Now I want to call this javascript function from the input tag in jsp where I am displaying the value of date. Check below
This is one way I tried to do:
<input size="13" name="startDate" maxLength="255" value=<script>formatDate("<%=startDate%>")</script> onChange="checkDate(this)">
I even tried this:
<input size="13" name="startDate" maxLength="255" value="'formatDate(<%=startDate%>)'" onChange="checkDate(this)">
But it dosen't work
Please help. I am struggling on this for days.
Thanks,
RubyHey all you developers out there , Pleaseeee help me with this one.
-
we are doing a prject on VPN or virtual private networks.. for this we have created the front end.. and in many pages there are operations performed such as file uploading, create users and so on.. so when these submit or upload buttons are clicked the server needs to take it to the appropriate page based on the success or failure of the operation.. for this we need to write jsp codes.. we hav seen a few of them.. but we are unable to proceed in this direction.. if we cold get the hang of writing codes for our purpose it would be great..
Start here at part II: [http://java.sun.com/javaee/5/docs/tutorial/doc/].
For the uploading part, use Apache Commons FileUpload: [http://commons.apache.org/fileupload]. -
Help needed to run JSTL 1.1 in Tomcat 6.0.16
Hi All,Help needed to run JSTL 1.1 in Tomcat 6.0.16. I am trying to run the example given in http://tomcat.apache.org/tomcat-6.0-doc/jndi-datasource-examples-howto.html The example tries to connect to MySQL database from JSP using JSTL and JNDI Datasource.I am running the example using Eclipse 3.4.2 using Sysdeo plugin to start and stop Tomcat server from Eclipse IDE.
My web.xml file has <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" id="WebApp_ID" version="2.5">
</web-app>
and test.jsp has proper taglib directives
<%@ taglib prefix="sql" uri="http://java.sun.com/jsp/jstl/sql" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
I have placed the jstl.jar and standard.jarof the jakarta-taglibs-standard-1.1.2.zip under E:\Deepa\workspace\DBTest\WebContent\WEB-INF\lib directory also placedcontext.xml file under E:\Deepa\workspace\DBTest\WebContent\META-INF and the content of context.xml is as below
<Context path="/DBTest" docBase="DBTest"
debug="5" reloadable="true" crossContext="true">
<Resource name="jdbc/TestDB" auth="Container" type="javax.sql.DataSource"
maxActive="100" maxIdle="30" maxWait="10000"
username="deepa" password="mysql" driverClassName="com.mysql.jdbc.Driver"
url="jdbc:mysql://localhost:3306/javatest?autoReconnect=true"/>
</Context>
Now while running the example, Eclipse creates one DBTest.xml file under C:\Program Files\Apache Software Foundation\Tomcat 6.0\conf\Catalina\localhost
which has the following line:
<Context path="/DBTest" reloadable="true" docBase="E:\Deepa\workspace\DBTest" workDir="E:\Deepa\workspace\DBTest\work" />
I am getting the following error when running http://localhost/DBTest/WebContent/test.jsp
in Browser:
<HTTP Status 500 -
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
org.apache.jasper.JasperException: The absolute uri: http://java.sun.com/jsp/jstl/sql cannot be resolved in either web.xml or the jar files deployed with this application
org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:51)
org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:409)
org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:116)
org.apache.jasper.compiler.TagLibraryInfoImpl.generateTLDLocation(TagLibraryInfoImpl.java:315)
org.apache.jasper.compiler.TagLibraryInfoImpl.<init>(TagLibraryInfoImpl.java:148)
org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:431)
org.apache.jasper.compiler.Parser.parseDirective(Parser.java:494)
org.apache.jasper.compiler.Parser.parseElements(Parser.java:1444)
org.apache.jasper.compiler.Parser.parse(Parser.java:138)
org.apache.jasper.compiler.ParserController.doParse(ParserController.java:216)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:103)
org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:154)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:315)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:295)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:282)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:586)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:317)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:342)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:267)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
In the Tomcat Server console, I am getting the following error:
INFO: Server startup in 7295 ms
May 20, 2009 6:36:48 AM org.apache.jasper.compiler.TldLocationsCache processWebDotXml
WARNING: Internal Error: File /WEB-INF/web.xml not found
May 20, 2009 6:36:48 AM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet jsp threw exception
org.apache.jasper.JasperException: The absolute uri: http://java.sun.com/jsp/jstl/sql cannot be resolved in either web.xml or the jar files deployed with this application
what is the problem with my code?
When running the same example, by creating a local server in Eclipse(creating new Server connection pointing to same Tomcat 6.0 installation) it runs fine without any error.Hi evnafets,
Wow, very helpful information, great insight into working of Eclipse. Thanks a lot.
I have one more question. I have a context.xml file under {color:#0000ff}E:\Deepa\workspace\DBTest\WebContent\META-INF{color} folder and that has the Resource element to connect to MySQL database:
{code{color:#000000}}{color}<Context path="/DBTest" docBase="DBTest" debug="5" reloadable="true" crossContext="true">
<Resource name="jdbc/TestDB" auth="Container" type="javax.sql.DataSource" maxActive="100" maxIdle="30" maxWait="10000" username="deepa" password="mysql" driverClassName="com.mysql.jdbc.Driver"
{color:#0000ff}url="jdbc:mysql://localhost:3306/javatest?autoReconnect=true"/>{color}
{color:#0000ff}</Context>{color}As usual when running application in local Tomcat server of Eclipse, this data source works fine. But when I run the application on Tomcat, by starting Sysdeo plugin from Eclipse, the DBTest.xml file created in C:\Tomcat 6.0\conf\Catalina\localhost has the context entry as<Context path="/DBTest" reloadable="true" docBase="E:\Deepa\workspace\DBTest\WebContent" workDir="E:\Deepa\workspace\DBTest\work">
</Context>The<Resource> element I have specified in the context.xml of \WebContent\META-INF folder is not taken into account by Tomcat and it gives the following error:May 21, 2009 5:20:04 AM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet jsp threw exception
javax.servlet.jsp.JspException: Unable to get connection, DataSource invalid: "org.apache.tomcat.dbcp.dbcp.SQLNestedException_: Cannot create JDBC driver of class '' for connect URL 'null'"
_at org.apache.taglibs.standard.tag.common.sql.QueryTagSupport.getConnection(_QueryTagSupport.java:276_)
at org.apache.taglibs.standard.tag.common.sql.QueryTagSupport.doStartTag(_QueryTagSupport.java:159_)
at org.apache.jsp.test_jsp._jspx_meth_sql_005fquery_005f0(_test_jsp.java:113_)
at org.apache.jsp.test_jsp._jspService(_test_jsp.java:66_)
at org.apache.jasper.runtime.HttpJspBase.service(_HttpJspBase.java:70_)
at javax.servlet.http.HttpServlet.service(_HttpServlet.java:717_)
at org.apache.jasper.servlet.JspServletWrapper.service(_JspServletWrapper.java:374_)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(_JspServlet.java:342_)
at org.apache.jasper.servlet.JspServlet.service(_JspServlet.java:267_)
at javax.servlet.http.HttpServlet.service(_HttpServlet.java:717_)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(_ApplicationFilterChain.java:290_)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(_ApplicationFilterChain.java:206_)
at org.apache.catalina.core.StandardWrapperValve.invoke(_StandardWrapperValve.java:233_)
at org.apache.catalina.core.StandardContextValve.invoke(_StandardContextValve.java:191_)
at org.apache.catalina.core.StandardHostValve.invoke(_StandardHostValve.java:128_)
at org.apache.catalina.valves.ErrorReportValve.invoke(_ErrorReportValve.java:102_)
at org.apache.catalina.core.StandardEngineValve.invoke(_StandardEngineValve.java:109_)
at org.apache.catalina.connector.CoyoteAdapter.service(_CoyoteAdapter.java:286_)
at org.apache.coyote.http11.Http11Processor.process(_Http11Processor.java:845_)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(_Http11Protocol.java:583_)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(_JIoEndpoint.java:447_)
at java.lang.Thread.run(_Thread.java:619_)
{code}
So to overcome this error I had to place the <Resource> element in DBTest.xml under C:\Tomcat 6.0\conf\Catalina\localhost {color:#000000}and then it works fine. {color}{color:#ff0000}*Why is the context.xml file in META-INF not considered by Tomcat server using Sysdeo Plugin?*
*Thanks,*
*Deepa*{color}
{color}
Edited by: Deepa76 on May 26, 2009 9:32 PM -
Help needed with this form in DW
Hi, i have created this form in dreamweaver but ive got this problem.
In the fields above the text field, the client needs to fill in some info such as name, email telephone number etc.
But the problem is when ill get the messages. Only the text from the large text field is there.
What did i do wrong??
http://www.hureninparamaribo.nl/contact.html
Thank you
Anybody??Thank you for your response. So what do i have to do to fix this?
Date: Sun, 20 Jan 2013 07:57:56 -0700
From: [email protected]
To: [email protected]
Subject: Help needed with this form in DW
Re: Help needed with this form in DW
created by Ken Binney in Dreamweaver General - View the full discussion
You have several duplicate "name" attributes in these rows which also appears in the first row
Telefoon:
Huurperiode:
Aantal personen:
Please note that the Adobe Forums do not accept email attachments. If you want to embed a screen image in your message please visit the thread in the forum to embed the image at http://forums.adobe.com/message/5008247#5008247
Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page: http://forums.adobe.com/message/5008247#5008247
To unsubscribe from this thread, please visit the message page at http://forums.adobe.com/message/5008247#5008247. In the Actions box on the right, click the Stop Email Notifications link.
Start a new discussion in Dreamweaver General by email or at Adobe Community
For more information about maintaining your forum email notifications please go to http://forums.adobe.com/message/2936746#2936746. -
Help need to switch Muse site to BC on a allready hosted plan
Hi, i also posted on BC forum...
I have a client that was in a hurry to have his emails accounts before the entire website.
So i went on and bought the email marketing plan (cos he will also need to do email campains) an pointed his domain everything is working fine, at this moment he has his accounts the domain is live.
The site would be just a small 7-10 pages not to complicated.
Has a graphic designer (who has venture into Business catalyst cos it had all the solutions i needed, well that's what the promotional videos said anyway) I made a site in Muse.
First i did a temporary page thats says "comming soon", and then i made the entire site, all the design and menu but with blank pages cos the client didnt have all the content yet (and still dont have). I uploaded that site to a sub directory so he could see the evolution.
He approved the design, yay!
At the end of the process, he told me he needed to have full control with the editor. (style, images, bulleted list, need to put downloadable document like pdf etc.) i told him that he could only modify what was allready there with the Muse in Browser editing (that he saw when i made the pitch using another site) he was impress with the way it worked.
so i told him i would have to remake "template".
I thought of using a BC template, and modify the looks to adapt to my client image, Of course, use a responsive theme so he could make the change at one place only. (cos in Muse you need to make the changes on the 3 layouts).
Now, i created a new temporary site using one of the new responsive template available.
How can i import that new site onto his live domain? In other words, how can a switch from a theme made in Muse, to a BC template?
cant i just delete everything in the root folder, and upload the entire new site via ftp?
please help me find the solution. i am a bit in a panic here
hope you could understand my lousy English.
Sincerely,
i.d.This would need to be transparent for m'y client...
Y
Envoyé de mon iPhone
Le 2014-04-20 à 15:29, Sanjit_Das <[email protected]> a écrit :
Re: help need to switch Muse site to BC on a allready hosted plan
created by Sanjit_Das in Help with using Adobe Muse CC - View the full discussion
Thanks for additional details.
Unfortunately we cannot change site template of a live site in BC , but as a workaround Create a site from BC using the template you wish to use then publish the site from Muse to the site created from BC and transfer the contents stored from live site to trial site. Ater final transition is done , you can delete the already paid site and make live the new trial site which includes new site template.
Thanks,
Sanjit
Please note that the Adobe Forums do not accept email attachments. If you want to embed a screen image in your message please visit the thread in the forum to embed the image at http://forums.adobe.com/message/6314730#6314730
Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page: http://forums.adobe.com/message/6314730#6314730
To unsubscribe from this thread, please visit the message page at http://forums.adobe.com/message/6314730#6314730. In the Actions box on the right, click the Stop Email Notifications link.
Start a new discussion in Help with using Adobe Muse CC at Adobe Community
For more information about maintaining your forum email notifications please go to http://forums.adobe.com/thread/416458?tstart=0. -
Help needed:Printing HTML file using javax.print
Hi
I am using the following code which i got form the forum for rpinting an HTML file.
The folllowing code is working fine, but the problem is the content of HTML file is not getting printed. I am geeting a blank page with no content. What is the change that is required in the code? ALso is there any simpler way to implement this. Help needed ASAP.
public boolean printHTMLFile(String filename) {
try {
JEditorPane editorPane = new JEditorPane();
editorPane.setEditorKit(new HTMLEditorKit());
//editorPane.setContentType("text/html");
editorPane.setSize(500,500);
String text = getFileContents(filename);
if (text != null) {
editorPane.setText(text);
} else {
return false;
printEditorPane(editorPane);
return true;
} catch (Exception tce) {
tce.printStackTrace();
return false;
public String getFileContents(String filename) {
try {
File file = new File(filename);
BufferedReader br = new BufferedReader(new FileReader(file));
String line;
StringBuffer sb = new StringBuffer();
while ((line = br.readLine()) != null) {
sb.append(line);
br.close();
return sb.toString();
} catch (Exception tce) {
tce.printStackTrace();
return null;
public void printEditorPane(JEditorPane editorPane) {
try {
HTMLPrinter htmlPrinter = new HTMLPrinter();
htmlPrinter.printJEditorPane(editorPane, htmlPrinter.showPrintDialog());
} catch (Exception tce) {
tce.printStackTrace();
* Sets up to easily print HTML documents. It is not necessary to call any of the setter
* methods as they all have default values, they are provided should you wish to change
* any of the default values.
public class HTMLPrinter {
public int DEFAULT_DPI = 72;
public float DEFAULT_PAGE_WIDTH_INCH = 8.5f;
public float DEFAULT_PAGE_HEIGHT_INCH = 11f;
int x = 100;
int y = 80;
GraphicsConfiguration gc;
PrintService[] services;
PrintService defaultService;
DocFlavor flavor;
PrintRequestAttributeSet attributes;
Vector pjlListeners = new Vector();
Vector pjalListeners = new Vector();
Vector psalListeners = new Vector();
public HTMLPrinter() {
gc = null;
attributes = new HashPrintRequestAttributeSet();
flavor = null;
defaultService = PrintServiceLookup.lookupDefaultPrintService();
services = PrintServiceLookup.lookupPrintServices(flavor, attributes);
// do something with the supported docflavors
DocFlavor[] df = defaultService.getSupportedDocFlavors();
for (int i = 0; i < df.length; i++)
System.out.println(df.getMimeType() + " " + df[i].getRepresentationClassName());
// if there is a default service, but no other services
if (defaultService != null && (services == null || services.length == 0)) {
services = new PrintService[1];
services[0] = defaultService;
* Set the GraphicsConfiguration to display the print dialog on.
* @param gc a GraphicsConfiguration object
public void setGraphicsConfiguration(GraphicsConfiguration gc) {
this.gc = gc;
public void setServices(PrintService[] services) {
this.services = services;
public void setDefaultService(PrintService service) {
this.defaultService = service;
public void setDocFlavor(DocFlavor flavor) {
this.flavor = flavor;
public void setPrintRequestAttributes(PrintRequestAttributeSet attributes) {
this.attributes = attributes;
public void setPrintDialogLocation(int x, int y) {
this.x = x;
this.y = y;
public void addPrintJobListener(PrintJobListener pjl) {
pjlListeners.addElement(pjl);
public void removePrintJobListener(PrintJobListener pjl) {
pjlListeners.removeElement(pjl);
public void addPrintServiceAttributeListener(PrintServiceAttributeListener psal) {
psalListeners.addElement(psal);
public void removePrintServiceAttributeListener(PrintServiceAttributeListener psal) {
psalListeners.removeElement(psal);
public boolean printJEditorPane(JEditorPane jep, PrintService ps) {
if (ps == null || jep == null) {
System.out.println("printJEditorPane: jep or ps is NULL, aborting...");
return false;
// get the root view of the preview pane
View rv = jep.getUI().getRootView(jep);
// get the size of the view (hopefully the total size of the page to be printed
int x = (int) rv.getPreferredSpan(View.X_AXIS);
int y = (int) rv.getPreferredSpan(View.Y_AXIS);
// find out if the print has been set to colour mode
DocPrintJob dpj = ps.createPrintJob();
PrintJobAttributeSet pjas = dpj.getAttributes();
// get the DPI and printable area of the page. use default values if not available
// use this to get the maximum number of pixels on the vertical axis
PrinterResolution pr = (PrinterResolution) pjas.get(PrinterResolution.class);
int dpi;
float pageX, pageY;
if (pr != null)
dpi = pr.getFeedResolution(PrinterResolution.DPI);
else
dpi = DEFAULT_DPI;
MediaPrintableArea mpa = (MediaPrintableArea) pjas.get(MediaPrintableArea.class);
if (mpa != null) {
pageX = mpa.getX(MediaPrintableArea.INCH);
pageY = mpa.getX(MediaPrintableArea.INCH);
} else {
pageX = DEFAULT_PAGE_WIDTH_INCH;
pageY = DEFAULT_PAGE_HEIGHT_INCH;
int pixelsPerPageY = (int) (dpi * pageY);
int pixelsPerPageX = (int) (dpi * pageX);
int minY = Math.max(pixelsPerPageY, y);
// make colour true if the user has selected colour, and the PrintService can support colour
boolean colour = pjas.containsValue(Chromaticity.COLOR);
colour = colour & (ps.getAttribute(ColorSupported.class) == ColorSupported.SUPPORTED);
// create a BufferedImage to draw on
int imgMode;
if (colour)
imgMode = BufferedImage.TYPE_3BYTE_BGR;
else
imgMode = BufferedImage.TYPE_BYTE_GRAY;
BufferedImage img = new BufferedImage(pixelsPerPageX, minY, imgMode);
Graphics myGraphics = img.getGraphics();
myGraphics.setClip(0, 0, pixelsPerPageX, minY);
myGraphics.setColor(Color.WHITE);
myGraphics.fillRect(0, 0, pixelsPerPageX, minY);
java.awt.Rectangle rectangle=new java.awt.Rectangle(0,0,pixelsPerPageX, minY);
// call rootView.paint( myGraphics, rect ) to paint the whole image on myGraphics
rv.paint(myGraphics, rectangle);
try {
// write the image as a JPEG to the ByteArray so it can be printed
Iterator writers = ImageIO.getImageWritersByFormatName("jpeg");
ImageWriter writer = (ImageWriter) writers.next();
// mod: Added the iwparam to create the highest quality image possible
ImageWriteParam iwparam = writer.getDefaultWriteParam();
iwparam.setCompressionMode(ImageWriteParam.MODE_EXPLICIT) ;
iwparam.setCompressionQuality(1.0f); // highest quality
ByteArrayOutputStream out = new ByteArrayOutputStream();
ImageOutputStream ios = ImageIO.createImageOutputStream(out);
writer.setOutput(ios);
// get the number of pages we need to print this image
int imageHeight = img.getHeight();
int numberOfPages = (int) Math.ceil(minY / (double) pixelsPerPageY);
// print each page
for (int i = 0; i < numberOfPages; i++) {
int startY = i * pixelsPerPageY;
// get a subimage which is exactly the size of one page
BufferedImage subImg = img.getSubimage(0, startY, pixelsPerPageX, Math.min(y - startY, pixelsPerPageY));
// mod: different .write() method to use the iwparam parameter with highest quality compression
writer.write(null, new IIOImage(subImg, null, null), iwparam);
SimpleDoc sd = new SimpleDoc(out.toByteArray(), DocFlavor.BYTE_ARRAY.JPEG, null);
printDocument(sd, ps);
// reset the ByteArray so we can start the next page
out.reset();
} catch (PrintException e) {
System.out.println("Error printing document.");
e.printStackTrace();
return false;
} catch (IOException e) {
System.out.println("Error creating ImageOutputStream or writing to it.");
e.printStackTrace();
return false;
// uncomment this code and comment out the 'try-catch' block above
// to print to a JFrame instead of to the printer
/* JFrame jf = new JFrame();
PaintableJPanel jp = new PaintableJPanel();
jp.setImage( img );
JScrollPane jsp = new JScrollPane( jp );
jf.getContentPane().add( jsp );
Insets i = jf.getInsets();
jf.setBounds( 0, 0, newX, y );
jf.setDefaultCloseOperation( JFrame.DISPOSE_ON_CLOSE );
jf.setVisible( true );*/
return true;
* Print the document to the specified PrintService.
* This method cannot tell if the printing was successful. You must register
* a PrintJobListener
* @return false if no PrintService is selected in the dialog, true otherwise
public boolean printDocument(Doc doc, PrintService ps) throws PrintException {
if (ps == null)
return false;
addAllPrintServiceAttributeListeners(ps);
DocPrintJob dpj = ps.createPrintJob();
addAllPrintJobListeners(dpj);
dpj.print(doc, attributes);
return true;
public PrintService showPrintDialog() {
return ServiceUI.printDialog(gc, x, y, services, defaultService, flavor, attributes);
private void addAllPrintServiceAttributeListeners(PrintService ps) {
// add all listeners that are currently added to this object
for (int i = 0; i < psalListeners.size(); i++) {
PrintServiceAttributeListener p = (PrintServiceAttributeListener) psalListeners.get(i);
ps.addPrintServiceAttributeListener(p);
private void addAllPrintJobListeners(DocPrintJob dpj) {
// add all listeners that are currently added to this object
for (int i = 0; i < pjlListeners.size(); i++) {
PrintJobListener p = (PrintJobListener) pjlListeners.get(i);
dpj.addPrintJobListener(p);
// uncomment this also to print to a JFrame instead of a printer
/* protected class PaintableJPanel extends JPanel {
Image img;
protected PaintableJPanel() {
super();
public void setImage( Image i ) {
img = i;
public void paint( Graphics g ) {
g.drawImage( img, 0, 0, this );
Thanks
RamRam,
I have had printing problems too a year and a half ago. I used all printing apis of java and I still find that it is something java lacks. Now basically you can try autosense. To check whether your printer is capable of printing the docflavor use this PrintServiceLookup.lookupPrintServices(flavor, aset); . If it lists the printer then he can print the document otherwise he can't. I guess that is why you get the error.
Regards,
Kevin -
Color management help needed for adobe CS5 and Epson printer 1400-Prints coming out too dark with re
Color management help needed for adobe CS5 and Epson printer 1400-Prints coming out too dark with reddish cast and loss of detail
System: Windows 7
Adobe CS5
Printer: Epson Stylus Photo 1400
Paper: Inkjet matte presentation paper with slight luster
Installed latest patch for Adobe CS5
Epson driver up to date
After reading solutions online and trying them for my settings for 2 days I am still unable to print what I am seeing on my screen in Adobe CS5. I calibrated my monitor, but am not sure once calibration is saved if I somehow use this setting in Photoshop’s color management.
The files I am printing are photographs of dogs with lots of detail I digitally painted with my Wacom tablet in Photoshop CS5 and then printed with Epson Stylus 1400 on inkjet paper 20lb with slight luster.
My Printed images lose a lot of the detail & come out way to dark with a reddish cast and loss of detail when I used these settings in the printing window:
Color Handling: Photoshop manages color, Color management -ICM, OFF no color adjustment.
When I change to these settings in printer window: Color Handling: Printer manages color. Color management- Color Controls, 1.8 Gamma and choose Epson Standard it prints lighter, but with reddish cast and very little detail and this is the best setting I have used so far.
Based on what I have read on line, I think the issue is mainly to do with what controls are set in the Photoshop Color Settings window and the Epson Printer preferences. I have screen images attached of these windows and would appreciate knowing what you recommend I enter for each choice.
Also I am confused as to what ICM color management system to use with this printer and CS5:
What is the best ICM to use with PS CS5 & the Epson 1400 printer? Should I use the same ICM for both?
Do I embed the ICM I choose into the new files I create?
Do I view all files in the CS5 workspace in this default ICM?
Do I set my monitor setting to the same ICM?
If new file opens in CS5 workspace and it has a different embedded profile than my workspace, do I convert it?
Do I set my printer, Monitor and PS CS5 color settings to the same ICM?
Is using the same ICM for all devices what is called a consistent workflow?
I appreciate any and all advice that can be sent my way on this complicated issue. Thank you in advance for your time and kind help.It may be possible to figure out by watching a Dr.Brown video on the subject of color printing. Adobe tv
I hope this may help............... -
Help needed to resolve there is no attribute X errors..
On my website http://www.dorffdesign.nl/ there is a problem. Ive put the FB Like button there and it worked fine for a while. But now its gone. So ive run
http://validator.w3.org/ on it and came up with the next errors:
========================================================================================== ==============================================
Line 232, Column 32: there is no attribute "data-href" <div class="fb-like" data-href="http://www.dorffdesign.nl/" data-send="true" da… ✉
Line 232, Column 71: there is no attribute "data-send" …http://www.dorffdesign.nl/" data-send="true" data-width="450" data-show-faces=… ✉
Line 232, Column 89: there is no attribute "data-width" …orffdesign.nl/" data-send="true" data-width="450" data-show-faces="true"></div> ✉
Line 232, Column 111: there is no attribute "data-show-faces" …orffdesign.nl/" data-send="true" data-width="450" data-show-faces="true"></div>
========================================================================================== ===============================================
In dreamweaver ive use this code for the FB likke button:
<div id="fb-root"></div>
<script>(function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) return;
js = d.createElement(s); js.id = id;
js.src = "//connect.facebook.net/nl_NL/all.js#xfbml=1";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
========================================================================================== ===========
<div class="fb-like" data-href="http://www.dorffdesign.nl/" data-send="true" data-width="450" data-show-faces="true"></div>
I really want to solve this so im hoping if you can point me into the right direction.
RegardsHi ive bin able to put the fb like button on my page. But i totally forgot how i have to place the fb like button under the black box named portfolio.
I hope you can tell me.
Regards
Date: Wed, 7 Nov 2012 07:41:54 -0700
From: [email protected]
To: [email protected]
Subject: Help needed to resolve there is no attribute X errors..
Re: Help needed to resolve there is no attribute X errors..
created by MurraySummers in Dreamweaver General - View the full discussion
You can either ignore those errors (since they have no impact on your page's functionality) or you can use DW to convert your page to an HTML5 doctype (File > Convert > HTML 5, and then the errors will go away.
Please note that the Adobe Forums do not accept email attachments. If you want to embed a screen image in your message please visit the thread in the forum to embed the image at http://forums.adobe.com/message/4829606#4829606
Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page: http://forums.adobe.com/message/4829606#4829606
To unsubscribe from this thread, please visit the message page at http://forums.adobe.com/message/4829606#4829606. In the Actions box on the right, click the Stop Email Notifications link.
Start a new discussion in Dreamweaver General by email or at Adobe Community
For more information about maintaining your forum email notifications please go to http://forums.adobe.com/message/2936746#2936746. -
Help needed with header and upload onto business catalyst
Can someone help with a problem over a header please?
I have inserted a rectangle with a jpeg image in background, in the 'header' section, underneath the menu. It comes up fine on most pages when previsualised, going right to the side of the screen, but stops just before the edge on certain pages. I have double checked that I have placed it in the right place in relation to the guides on the page.
That's one problem.
The second problem is that I tried to upload onto business catalyst, which got to 60% and refused to go any further, saying it couldn't find the header picture, giving the title and then u4833-3.fr.png. The picture is in the right folder I have double checked. And it isn't a png. Does it have to be ?
And the third problem is that I got an email following my upload from business catalyst in Swedish. I am living in France.
Can anyone help ? Thanks.Thanks for replying,
How can I check the preview in other browsers before I publish a provisional site with BC?
The rectangle width issue happens on certain pages but not others. The Welecom page is fine when the menu is active, also the contact page, but others are slightly too narrow. Changing the menu spacing doesn’t help - I was already on uniform but tried changing to regular and back.
In design mode the rectangle is set to the edge of the browser, that’s 100%browser width right?
Re BC I have about 200 images on 24 different pages and it seems to be having difficulty uploading some of them. But it has managed a couple I named with spaces but not others I named with just one name.
Is there an issue on size of pictures ? If I need to replace is there a quick way to rename and relink or do I have to insert the photos all over again?
I’m a novice with Muse with an ambitious site !
Thanks for your help.
Mary Featherstone
Envoyé depuis Courrier Windows
De : Sanjit_Das
Envoyé : vendredi 14 février 2014 22:15
À : MFeatherstone
Re: Help needed with header and upload onto business catalyst
created by Sanjit_Das in Help with using Adobe Muse CC - View the full discussion
Hi
Answering the questions :
- Have you checked the preview in Muse and also in other browsers ?
- Does the rectangle width issue happens when menu is active , or in any specific state , Try to change the menu with uniform spacing and then check.
- In design view the rectangle is set to 100% browser width ?
With publishing :
- Please try to rename the image file and then relink
- If it happens with other images as well , see if all the image names includes strange characters or spaces.
- Try again to publish
With e-mail from BC :
- Under preferences , please check the country selected.
- If you have previously created partner account in BC and selected country and language then it would follow that, please check that.
Thanks,
Sanjit
Please note that the Adobe Forums do not accept email attachments. If you want to embed a screen image in your message please visit the thread in the forum to embed the image at http://forums.adobe.com/message/6121942#6121942
Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page: http://forums.adobe.com/message/6121942#6121942
To unsubscribe from this thread, please visit the message page at http://forums.adobe.com/message/6121942#6121942. In the Actions box on the right, click the Stop Email Notifications link.
Start a new discussion in Help with using Adobe Muse CC at Adobe Community
For more information about maintaining your forum email notifications please go to http://forums.adobe.com/thread/416458?tstart=0. -
I am using CONOS and ApplicationXtender. COGNOS generates the report - ApplicationXtender stores the data. I need to EMBED a PDF, possibly as a link in the report
AHUnfortunately your post is off topic here, in the TechNet Site Feedback forum, because it is not Feedback about the TechNet Website or Subscription. This is only one forum among the many that are on the TechNet Discussion Forums, and given
your post, you likely chose the wrong forum. This is a standard response I’ve written up in advance to help many people (thousands, really.) who post their question in this forum in error, but please don’t ignore it. The links I share below I’ve
collected to help you get right where you need to go with your issue.
For technical issues with Microsoft products that you would run into as an
end user of those products, one great source of info and help is
http://answers.microsoft.com, which has sections for Windows, Hotmail, Office, IE, and other products. Office related forums are also here:
http://office.microsoft.com/en-us/support/contact-us-FX103894077.aspx
For Technical issues with Microsoft products that you might have as an
IT professional (like technical installation issues, or other IT issues), you should head to the TechNet Discussion forums at
http://social.technet.microsoft.com/forums/en-us, and search for your product name.
For issues with products you might have as a Developer (like how to talk to APIs, what version of software do what, or other developer issues), you should head to the MSDN discussion forums at
http://social.msdn.microsoft.com/forums/en-us, and search for your product or issue.
If you’re asking a question particularly about one of the Microsoft Dynamics products, a great place to start is here:
http://community.dynamics.com/
If you really think your issue is related to the subscription or the TechNet Website, and I screwed up, I apologize! Please repost your question to the discussion forum and include much more detail about your problem, that could include screenshots
of the issue (do not include subscription information or product keys in your screenshots!), and/or links to the problem you’re seeing.
If you really had no idea where to post this question but you still posted it here, you still shouldn’t have because we have a forum just for you! It’s called the Where is the forum for…? forum and it’s here:
http://social.msdn.microsoft.com/forums/en-us/whatforum/
Moving to off topic.
Thanks, Mike
MSDN and TechNet Subscriptions Support -
Having trouble with SQLServer 2008 (not MySQL) and my database connection in Dreamweaver CS6. My document type is set as .asp using VBScript. I can list the table information but cannot use the insert wizard to add new records. I don't get any errors after creating the insert form, but no records get inserted. I'm not a VBScript expert, but do I have to manually write some code to insert records? How do I attach it to a button?
Thanks for the quick reply. I won't be back in the office for a few days, but I'll try to post it when I get back in. It's pretty much the code generated from the Dreamweaver Insert Record wizard. I see where the submit button is created and the value is set but the action on the form is set to MM_insert, so I don't see where the submit code is actually called.
Date: Wed, 3 Oct 2012 12:06:14 -0600
From: [email protected]
To: [email protected]
Subject: SQL Server2008 help needed
Re: SQL Server2008 help needed
created by bregent in Dreamweaver General - View the full discussion
This post should be moved to the app dev forum. Please post the code from your form and the insert script pages.
Please note that the Adobe Forums do not accept email attachments. If you want to embed a screen image in your message please visit the thread in the forum to embed the image at http://forums.adobe.com/message/4746757#4746757
Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page: http://forums.adobe.com/message/4746757#4746757
To unsubscribe from this thread, please visit the message page at http://forums.adobe.com/message/4746757#4746757. In the Actions box on the right, click the Stop Email Notifications link.
Start a new discussion in Dreamweaver General by email or at Adobe Community
For more information about maintaining your forum email notifications please go to http://forums.adobe.com/message/2936746#2936746.
Maybe you are looking for
-
Problem with audio and vga adapter in presentations
this is an odd problem. I potted a presentation that contained a qt movie. The video plays with sound just fine via the vga adapter until you plug in an external speaker system or earphone. the sound stops. if you play a video outside keynote or play
-
Hi, I hav created a procedure to create a daily view with 62 tables somthing like this Create or replace Procedure View_Cre as ex_command LONG:= null; ex1_command LONG:= null; ex2_command LONG:= null; ex3_command LONG:= null; begin ex1_command :='CRE
-
I'm a newbie: I have a question about threads
midp 2.0 Java SE 5.0 J2ME version 2.2 Below is my code I'm stucked with..... The code here shows a midlet class and another class derived from Thread (NetworkThread). This NetworkThread gets started from the main midlet... Search my code for the term
-
I am facing an Issue as below and hence seek your views For a Sales order, the confirmation of schedule lines is as below: AS it is visible, the Qty of 3 pc was scheduled to be confirmed later. The confirmation is 3 units short even though the order
-
Security Actions Necessary to develop BPM processes
Hello, could anyone tell me which security actions are necessary to develop BPM-processes. For deployment, Sap-help says the following: *every user needs to have dc_action action to be able to read deployment related information *if you want