BACKGROUND IN DREAMWEAVER_PLEASE HELP NEED EXACT FIT

I am trying to put a background on my site but do not want
the background to fill the entire page. I only would like it to fit
about 400x500 of a section in the back of some text. The problem is
when I load it in, it fills the whole page and not the exact size I
want.
someone please help

What will happen to your exact fit when someone resizes that
text in their
browser?
Murray --- ICQ 71997575
Adobe Community Expert
(If you *MUST* email me, don't LAUGH when you do so!)
==================
http://www.dreamweavermx-templates.com
- Template Triage!
http://www.projectseven.com/go
- DW FAQs, Tutorials & Resources
http://www.dwfaq.com - DW FAQs,
Tutorials & Resources
http://www.macromedia.com/support/search/
- Macromedia (MM) Technotes
==================
"WebGuyDesign" <[email protected]> wrote in
message
news:em9dgp$dcn$[email protected]..
>I am trying to put a background on my site but do not
want the background
>to
> fill the entire page. I only would like it to fit about
400x500 of a
> section
> in the back of some text. The problem is when I load it
in, it fills the
> whole
> page and not the exact size I want.
>
> someone please help
>

Similar Messages

  • Removing color gradient background from video - help needed

    Hello everyone,
    I shot my son playing the violin against a white backdrop today, and what was pure white didn't turn out to be very white, I have gray
    areas, off white areas because of incorrect lighting.
    I want the background to be more white and more even than what it is right now.
    I thought of moving the video from track 1 up to track 2.
    I added in a title, which consists of a big box of white ( using the retangular tool I just drew a large white retangle that covers the entire movie area )
    Now to remove some of that white backdrop, I thought I would try some of the tools below, to remove the real backdrop, and let the white retangle
    from track 1 come through. ( so that the pure white comes through from track 1. )
    I've been going through the various options,
    - Chroma Key
    - Color Key
    - Change Color
    - Change To Color
    After 30 some minutes of fldding around, I thought I would just stop, and ask for help.  How would you proceed with this ?
    What process would you use ?
    I'm just puzzled as to which tool is best suited for a job like this, because right now my results are not to my liking, and it's just hard to get anything
    that looks good at all.
    Thanks for all help,
    Dave.

    Hi Harm,
    Thanks for the great response, I don't have Ultra CS3, but will look into Keylight.  I'm going to try the garbage mattes and chroma key route
    for now and see what I can do.
    You are indeed a weatlh of info.
    Thanks again,
    Dave.

  • Help Needed - FusionFx Style - How do I remove the Dashboard Grey Box Section, so that Dashboard Background is Blank

    Help Needed - FusionFx Style - How do I remove the Dashboard Grey Box Section, so that Dashboard Background is Blank
    We like FusionFx Style but would like to keep the background white like blafp style.

    Can you be a little more descriptive on what you need here and explain what exactly you want to be changed.

  • Nonlinear curve fit help needed

    I am in need of some help trying to fit a set of data that requires the use of nonlinear curve fitting.  I have attached a txt file containing the data that needs to be fitted.  The first row contains the x-axis values while the second row contains the y-axis values.  The model for this set of data can be described by a single parameter, A, for the first five data points.  The remainder of the data points can be described by the model A+A1*exp((0.4-x)/A2), where A, A1, and A2 are all parameter.  As you can see the two models share the parameter A.
    I have determined some initial values for each of the parameters: A=176.32, A1=2133.4133, and A2=1.4936.
    I have spent the last couple of days trying to figure out how to use the Lev-Mar nonlinear curve fit vi but have had little success.  I have been doing LabVIEW programing for many years now and I have never felt as lost as I do now trying to understand how the Lev-Mar nonlinear curve fit vi works.  Any help you can provide with my data fitting would be greatly appreciated.
    Thanks.
    -Alonzo
    Solved!
    Go to Solution.
    Attachments:
    Data.txt ‏1 KB

    I think the problem is that the first 5 points are not part of the data sent to Lev-Mar.  Because of this the fitting process fits the remaining data very well, but the constant term is able to freely move.  I modified the model function to output A for the first 5 terms, and the complete function for the rest.  The offset found is now more reasonable.
    Also, your quote your model to be A+A1*exp((0.4-x)/A2), but what is implemented in the model VI seems to be A+A1*exp((x-0.4)/A2).
    -Jim
    Attachments:
    ExponentialFunction.vi ‏19 KB
    FitExponentialExample.vi ‏24 KB

  • Please help me to get the website design in exact fit

    Hi,                           
    I developed a website that is 1280x840 and a few user had smaller screens were having problem checking the site in noscale mode. Now i set it to exact fit, but all the external movie clips are getting distorted, so what i was wondering is, if you have any sample codes that will resize those movie clips keeping its scale proportions, or if you have any other suggestions on what to do?
    Kind regards and thanks in advance for your replies...... 
    Nirmalatha

    Ehm. Before placing? At that point ID doesn't know anything at all about the PDF.
    var myPDFFile = File.openDialog("Choose a PDF File");
    myPDFFile.execute();
    Then check the lower left bottom -- it should display the page size.
    Why not first place the file and then check its size? You can always move it to the right position after placing.
    Oh, by the way: "a PDF" doesn't have a "page size". Each single page in a PDF can have a page size of its own.

  • Level 0 exact fit, level 1 original size in browser?

    Hello everybody!
    im searching for a help if anyone can help will be
    apreciated.
    I use one movie that should fit the full browser window, as a
    background, I used ExactFit from html and was just fine, and one
    movie that should be the website content on level 1. The probloem
    is that because of the exact fit of the level 0, the level 1 do the
    same when is loaded over the level 0, resize to the exact fit.
    Anyone know how to load the level 0 ( as a background ) to fit the
    whole window of the browser but the level 1 to use his size, and
    not resize as the level 0 ?
    thank you very very much

    I use this code that resize the background ( _level0 ) when
    you resize the window browser.
    But anything that is loaded as level 1 or 2 etc, I whant to
    have the original size. Anyone know how to fix this ??
    var scaleMode_cb:mx.controls.ComboBox;
    scaleMode_cb.dataProvider = ["showAll", "exactFit",
    "noBorder", "noScale"];
    var cbListener
    bject = new Object();
    cbListener.change = function(evt
    bject) {
    var scaleMode_str:String = evt.target.selectedItem;
    Stage.scaleMode = scaleMode_str;
    scaleMode_cb.addEventListener("change", cbListener);

  • Help needed for writing query

    help needed for writing query
    i have the following tables(with data) as mentioned below
    FK*-foregin key (SUBJECTS)
    FK**-foregin key (COMBINATION)
    1)SUBJECTS(table name)     
    SUB_ID(NUMBER) SUB_CODE(VARCHAR2) SUB_NAME (VARCHAR2)
    2           02           Computer Science
    3           03           Physics
    4           04           Chemistry
    5           05           Mathematics
    7           07           Commerce
    8           08           Computer Applications
    9           09           Biology
    2)COMBINATION
    COMB_ID(NUMBER) COMB_NAME(VARCHAR2) SUB_ID1(NUMBER(FK*)) SUB_ID2(NUMBER(FK*)) SUB_ID3(NUMBER(FK*)) SUBJ_ID4(NUMBER(FK*))
    383           S1      9           4           2           3
    384           S2      4           2           5           3
    ---------I actually designed the ABOVE table also like this
    3) a)COMBINATION
    COMB_ID(NUMBER) COMB_NAME(VARCHAR2)
    383           S1
    384           S2
    b)COMBINATION_DET
    COMBDET_ID(NUMBER) COMB_ID(FK**) SUB_ID(FK*)
    1               383          9
    2               383          4
    3               383          2
    4               383          3
    5               384          4
    6               384          2          
    7               384          5
    8               384          3
    Business rule: a combination consists of a maximum of 4 subjects (must contain)
    and the user is less relevant to a COMB_NAME(name of combinations) but user need
    the subjects contained in combinations
    i need the following output
    COMB_ID COMB_NAME SUBJECT1 SUBJECT2      SUBJECT3      SUBJECT4
    383     S1     Biology Chemistry      Computer Science Physics
    384     S2     Chemistry Computer Science Mathematics Physics
    or even this is enough(what i actually needed)
    COMB_ID     subjects
    383           Biology,Chemistry,Computer Science,Physics
    384           Chemistry,Computer Science,Mathematics,Physics
    you can use any of the COMBINATION table(either (2) or (3))
    and i want to know
    1)which design is good in this case
    (i think SUB_ID1,SUB_ID2,SUB_ID3,SUB_ID4 is not a
    good method to link with same table but if 4 subjects only(and must) comes
    detail table is not neccessary )
    now i am achieving the result by program-coding in C# after getting the rows from oracle
    i am using oracle 9i (also ODP.NET)
    i want to know how can i get the result in the stored procedure itsef.
    2)how it could be designed in any other way.
    any help/suggestion is welcome
    thanks for your time --Pradeesh

    Well I forgot the table-alias, here now with:
    SELECT C.COMB_ID
    , C.COMB_NAME
    , (SELECT SUB_NAME
    FROM SUBJECTS
    WHERE SUB_ID = C.SUB_ID1) AS SUBJECT_NAME1
    , (SELECT SUB_NAME
    FROM SUBJECTS
    WHERE SUB_ID = C.SUB_ID2) AS SUBJECT_NAME2
    , (SELECT SUB_NAME
    FROM SUBJECTS
    WHERE SUB_ID = C.SUB_ID3) AS SUBJECT_NAME3
    , (SELECT SUB_NAME
    FROM SUBJECTS
    WHERE SUB_ID = C.SUB_ID4) AS SUBJECT_NAME4
    FROM COMBINATION C;
    As you need exactly 4 subjects, the columns-solution is just fine I would say.

  • HELP NEEDED WITH ADDAPTER-DVI TO VGA.

    PLEASE ...HELP NEEDED WITH WIRING CROSS OVER....CAN YOU HELP WITH BACK OF PLUG CONNECTIONS...I SORTA UNDERSTAND THE PINOUTS BUT CANT MAKE AN EXACT MACH...WOULD LIKE TO BE 100% SURE...
    ......THIS ENSURES NO SMOKE!!!                                                                                           
    THE CARD IS AN ATI RADEON RX9250-DUAL HEAD-.........ADDAPTER IS DVI(ANALOG)MALE TO VGA(ANALOG)FEMALE.
    ANY HELP VERY MUCH APPRECIATED........ SEEMS YOU NEED TO BE ROCKET SCI TO ATTACH A BLOODY PICTURE...SO THIS HAS BEEN BIG WASTE OF FING TIME!

    Quote from: BOBHIGH on 17-December-05, 09:21:31
    Get over it mate !
    I find it easy t read CAPS...and if you dont like it ...DONT READ IT!
    And why bother to reply...some people have nothing better to do.
    Yes there chep and easy to come by...Ive already got a new one.
    All I wanted was to make a diagram of whats inside the bloody thing...it was a simple question and required a simple answer.
    NO NEED TO A WANKA !!
    I feel a bann comming up.
    Have you tryed Google ? really.. your question is inrelevant. No need to reply indeed.
    Why do you come here asking this question anyway ? is it becouse you have a MSI gfx card ? and the adapter has nothing to do with this ?
    You think you can come in here yelling.. thinking we have to put up with it and accept your style of posting. This is not a MSI tech center.. it's a user to user center.. Your question has nothing to do with MSI relavant things anyway's.
    Google = your friend.
    Quote from: BOBHIGH on 17-December-05, 09:21:31
    it was a simple question and required a simple answer
    Simple for who ? you (buying a new one) ? me ? we ?   .really...........
    Quote from: Dynamike on 16-December-05, 04:11:48
    1: There are allot of diffrent types of those adapters.
    If any of the mods have a problem about my reply.. please pm me.

  • Help needed in constructing a tree

    Help needed in constructing a tree. I was wondering if some one can suggest me how to add messages in the second column for both the parent node and child elements.
    I was able to create a tree succefully, but want to add some description in the second column for the first column elements, for both parent and child elements.
    Please suggest me how to add the arrays to second column for parent and child nodes.
    Solved!
    Go to Solution.
    Attachments:
    Tree_fix.vi ‏15 KB

    The Child Text parameter is the one you are searching for. It accepts a 1D string array for the following columns.
    hope this helps,
    Norbert
    CEO: What exactly is stopping us from doing this?
    Expert: Geometry
    Marketing Manager: Just ignore it.

  • Help needed with Vista 64 Ultimate

    "Help needed with Vista 64 UltimateI I need some help in getting XFI Dolby digital to work
    Okay so i went out and I bought a yamaha 630BL reciever, a digital coaxial s/pdif, and a 3.5mm phono plug to fit perfectly to my XFI Extreme Music
    -The audio plays fine and reports as a PCM stream when I play it normally, but I can't get dolby digital or DTS to enable for some reason eventhough I bought the DDL & DTS Connect Pack for $4.72
    When I click dolby digital li've in DDL it jumps back up to off and has this [The operation was unsuccessful. Please try again or reinstall the application].
    Message Edited by Fuzion64 on 03-06-2009 05:33 AMS/PDIF I/O was enabled under speakers in control panel/sound, but S/PDIF Out function was totally disabled
    once I set this to enabled Dolby and DTS went acti've.
    I also have a question on 5. and Vista 64
    -When I game I normally use headphones in game mode or 2. with my headphones, the reason for this is if I set it on 5. I get sounds coming out of all of the wrong channels.
    Now when I watch movies or listen to music I switch to 5. sound in entertainment mode, but to make this work properly I have to open CMSS-3D. I then change it from xpand to stereo and put the slider at even center for 50%. If I use the default xpand mode the audio is way off coming out of all of the wrong channels.
    How do I make 5. render properly on vista

    We ended up getting iTunes cleanly uninstalled and were able to re-install without issue.  All is now mostly well.
    Peace...

  • Help needed in PS module on CJ9ECP/CJ20N for revaluating CCR??

    help needed in PS module on CJ9ECP/CJ20N for revaluating CCR??
    How to handle method on_costing_component_to_outtab which belongs to badi gui_itemization_ck. This is to revaluate CCR in CJ20N.
    From sale transaction(va01/va02) i need to call cj20n/cj9ecp for revaluating cost estimates. Can anyone say how to proceed with this thing.
    Can any one say how to handle pop up window in CJ20N/CJ9ECP when clicked edit ecp button. Later how to revaluate cost estimates. For this should i need to go for call transaction or is there any method available. If so how to handle method for revaluating cost estimates for ECP of WBS elements

    Thanks Amol for the advice.
    My friend doesn't belong to an engineering background and had not worked in a manufacturing environment.
    He holds an MBA degree specialised in systems and has worked in software companies supporting software projects and the functions(like HR,Procurement in the same setup) as a software quality guy.
    Moreover the modules mentioned by you requires engineering background with manufacturing exposure.
    He had enquired for the course at siemens and they said that he may not be suitable for any of the modules offered by them as per the above reasons.They also mentioned that they have to check with SAP Labs for expert opinion.
    Please provide your inputs.
    regards,
    Zubair.

  • URGENT HELP NEEDED ... Tomcat Realm and JRE1.4 plug-in problem

    I have tried the Security Realm of Tomcat. Since I do not have
    an LDAP server, I decided to use the Tomcat-users.xml file in
    Tomcat\conf directory.
    I added the following lines of code in the web.xml file.
    <security-constraint>
    <web-resource-collection>
    <web-resource-name>Entire Application</web-resource-name>
    <url-pattern>/*</url-pattern>
    </web-resource-collection>
    <auth-constraint>
    <!-- NOTE: This role is not present in the default users file -->
    <role-name>webviewer</role-name>
    </auth-constraint>
    </security-constraint>
    <login-config>
    <auth-method>BASIC</auth-method>
    <realm-name>Tomcat Manager Application</realm-name>
    </login-config>
    The <role-name> "webviewer" is added into "Tomcat-Users.xml" as the following:
    <tomcat-users>
    <user name="test" password="password" roles="webviewer" />
    </tomcat-users>
    So, now when we type the url: http://localhost:8080/adbpdbre/default.htm, TOMCAT shows a dialog box asking for UserName: and Password:Now, only when we give the username and password, it shows the page. This is exactly what we want.
    But the problem now is, this default.htm page, has 5 links to 5 applets. The first time that I click on one of these links, the JRE plug of 1.4 shows a dialog again asking for the username and password. Till I dont provide the username and password the system doesnt go ahead and applet doesnt load. I do not want the JRE to ask me for the username/passwords again..How to avoid this ?
    Can you give me some more information on this. Ultimately in the production usage, we will be using LDAP and not Tomcat's memory realm.
    URGENT HELP NEEDED ... I need to get back to my client on this.
    Help would be v. much appreciated.

    In the config file, you 're essentially saying that you want Tomcat to prompt for usr/passw on every request (url-pattern = /*) made by a 'webviewer', and that's exactly what Tomcat is doing.
    Consider using specific url-patterns & roles for resources to be protected. If for now, all you need is to protect the first page, use a more specific url-pattern.
    Just an advice : if you'll be using LDAP in production, do not waste time with Tomcat's Security Realm and the BASIC authentication type, since the two have not much in common. Start reading doc on LDAP, and code a prototype, or even better, a vertical slice of the app (i.e a proof of concept).

  • URGENT HELP NEEDED - iPhone 3Gs no longer detected or charged by MacBook

    My iPhone 3Gs (3.1) has been running fine, until several hours ago today, when I plugged it to my MacBook, the iPhone is no longer detected - it doesn't show up in iTunes, nor it is charged. I tried opening iPhoto, and it wasn't there too. Not with Image Capture too. I tried charging it using the out-of-box wall charger using the same out-of-box USB cable I use for MacBook, and it can be charged without any problem. Then I put it into Recovery mode, and there iTunes can see it. I don't want to restore it before I figure out exactly what went wrong, as I don't want the restore process somehow gets stuck in the middle that the connection is lost again.
    I've tried reinstalled iTunes, including completely removal of Apple Mobile Device Support, as instructed by Apple. But still no luck.
    I've tried switching to another USB port of my MacBook. No luck.
    My iTunes is the latest 9.0.1, and my Mac OSX is 10.6.1. My iPhone is on 3.1, upgraded from 3.0.
    I've read from web that it seems I'm not the only one out there having this problem. But none of them seem having any real working solution.
    Urgent help needed & appreciated. Millions of thanks in advance.
    Gary

    1. I used both cables - theirs & mine ... and on several macs
    2. yes, same cable for wall & mac
    3. as said, i did completely remove & install itunes (incl. apple mobile device support), as instructed on the apple webpage
    anyway, did a restore just now. it seems okay now. but the problem is i have no idea what cause this, and i can't replicate the problem. so i don't know when it will happen again ... maybe a bug with os 3.1 ... others on web said os 3.1 is quite buggy ...

  • HELP NEEDED PLEASE

    Hi everyone
    Programming help needed here. Any advice would be greatly appreciated!!!
    I have been assigned some work for a program called Processing 1.0 availale at http://processing.org/download
    I was give the 9 individual programs I needed to make however they were converted to Java files from .pde files. The program is based on Java but only runs .pde files and NOTHING else!
    I decompiled the files and got the source code, but it is a slight variation of the original someone made in processing, and needs some tidying to get it to run.
    I think the programs are very simple for a programmer, although I AM NOT.
    CODE is BELOW
    // Decompiled by DJ v3.10.10.93 Copyright 2007 Atanas Neshkov Date: 02/05/2009 13:15:00
    // Home Page: http://members.fortunecity.com/neshkov/dj.html http://www.neshkov.com/dj.html - Check often for new version!
    // Decompiler options: packimports(3)
    // Source File Name: Assign2_1.java
    import processing.core.PApplet;
    public class Assign2_1 extends PApplet
    public Assign2_1()
    SquareSide = 20;
    Rank = Nums.length;
    Side = SquareSide * Rank;
    Green = color(0, 255, 0);
    Yellow = color(255, 255, 0);
    BG = Yellow;
    public void setup()
    size(Side, Side);
    background(BG);
    fill(Green);
    for(int i = 0; i < Rank; i++)
    rect(i * SquareSide, 0.0F, SquareSide, SquareSide * Nums);
    public static void main(String args[])
    PApplet.main(new String[] {
    "--bgcolor=#ece9d8", "Assign2_1"
    int Nums[] = {
    6, 14, 8, 9, 2, 3, 4, 2, 8, 3,
    9, 2, 0, 5
    int SquareSide;
    int Rank;
    int Side;
    int Green;
    int Yellow;
    int BG;
    Edited by: chevy1 on May 2, 2009 7:32 AM

    HELP NEEDED PLEASEShouting is a good way ensure you don't get help. Also you should give a meaningful subject.
    Any advice would be greatly appreciated!!!I suggest you ask a question after providing enough information to be able to answer it.
    Also use CODE tags when posting code as it make the code more readable.
    We are more likely to help people who are trying to learn Java rather than someone who might be looking for an easy way out of doing an assignment.

  • 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
    Ram

    Ram,
    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

Maybe you are looking for

  • HP Expert Day – Got Questions? We have answers! Sept 20-21, '12.

    Check out the Expert Day event on the HP Support Forums! On September 20-21, HP Experts will be on the forums to help real time with any questions you have about your HP product. Do you have questions about Mac OS X, iOS and AirPrint™ for HP products

  • System copy based on export/import on MSCS

    Hi, a NW 7.0 istance (BW usage) on MSCS... we would like to copy to new host (as dev refresh). This MSCS is made of: - host1 (first node) - host2 (second node) - mscdhost (mscs virtual host) - orahost (oracle virtualhost... on a dedicated group) - sa

  • Landline Not Working, Can't report fault.

    Got up this morning and had to make an important phonecall only to find we had no dial tone, our broadband was also off but that problem seems to have been fixed. Our landline on the other hand hasn't and i can't report the fault as we have to do a l

  • The cursor movement is very 'slow' or 'inertial'

    Hi. I bought a mac mini with a magic mouse and connected it to a large LCD TV via HDMI (fullHD). Everything is excellent, save for the fact that the cursor movement is very 'slow' or 'inertial'.

  • Export changes the black point

    I've noticed that when exporting from LR4 (and LR3 for that matter) that on certain photos with deep blacks, the black point gets shifted during the export (for lack of a better term)  By this, I mean that on some of my dark (i.e. night and or low ke