Paint question

In my,
paint(Graphics g){...
can i add a mouse listener to images? so if i clicked on a specific image which had been drawn(g2D.drawImage(img...), my program would tell me the specific image name?
confused.

the problem is,
Ive got an array of strings in another class. Paint(graphics g...
uses drawString and drawImage to keep drawing a image with attached strings (5 per line, untill no more) from array.I need someway of being able to select specific strings/images drawn to screen by using the mouse.Im unsure of how to incorparate a label etc in paint?
any idea of how id do this?

Similar Messages

  • Report Painter question (FGI1) How to limit output up to a specified period

    Hello
    I have a report painter question.
    I am trying to create a BS report using tcode FGI1 (FALGFLEXT), that lists out the BS values by month (Jan - Dec).
    But the problem I am coming across is, if I specify selection parameter 01 2008, the report also populates the same values into the unposted months ahead (Feb/Mar/April)
    Something is wrong with my parameters.
    Is there a way I can limit the report output up to the specified period/month?
    I thought I might be able to work around this by creating a formula/variable (like in GL-SL), but it doesnt seem to be the case.
    Any thoughts appreciated
    regards
    Ken

    Period shall be included in the column characteristics. Check the variables or Values in column definition for the characteristic period.
    You could either give the values of period 1 for col 1, 2  for col 2, etc
    or you may use variables for period. The variables can be a formula variable with conditions.
    You make the user to enter a value for the 'To period'  (ZTOPRD)
    The value for the variable for column 2 (Feb) shall be  = 2, if ZTOPRD > or equal to  2  else, give some 17 .
    This way when the user enters a value of 1in the to period, the system would default 17, for which there won't be any values.
    You may extrapolate the above formula for various remaining columns of period.

  • Report painter question FI-GL or FI-SL?

    Hello
    I have a general question on reports created via report painter.
    I want to create a BS & PL report to see balances by month, and am trying to determine considerations to take into account.
    Creation of a report where I can see the balance of an entire year is my goal.
    From my limited understanding, I know I can create it in FI-GL or FI-SL.
    For FI-GL, the global variable formulas I need to create look to be a pain, since they reference user exits (to calculate periods 1-12). Maybe its not that difficult, but Im not that knowledgable on this yet.
    FI-SL (Special Ledger) is something that looks very usable, and I was planning on creating a special ledger and creating a BS report for it. But my concern is its reading from a different ledger. Are there cases where a discrepancy arises between ledgers?
    If anyone has any advice on the the FI-SL or report painter, I would appreciate it
    Regards,
    Ken

    Period shall be included in the column characteristics. Check the variables or Values in column definition for the characteristic period.
    You could either give the values of period 1 for col 1, 2  for col 2, etc
    or you may use variables for period. The variables can be a formula variable with conditions.
    You make the user to enter a value for the 'To period'  (ZTOPRD)
    The value for the variable for column 2 (Feb) shall be  = 2, if ZTOPRD > or equal to  2  else, give some 17 .
    This way when the user enters a value of 1in the to period, the system would default 17, for which there won't be any values.
    You may extrapolate the above formula for various remaining columns of period.

  • Report Painter Questions

    Hello,
    I am new to SAP and this forum and have been put in charge of report development for Finance for our organization.  I have been delving into report painter on my own with no official training on it and have a few questions I can't seem to find answers to.  I was hoping someone here could help.
    1.     What is the limit to the number of columns in a report painter report?
    2.     How do I get a literal in the body of a report?  In other words, I just want text to appear in one of the lines as a label which would mark different sections of the report.
    3.     Can I get both p&l activity and balance sheet balances (not activity) in the same column of a report painter report?
    4.     Is there a way to take report painter reports and import them into an already existing formatted template so that they look nice when printed?
    5.     How do I get headers to show up in the Excel option of report painter reports?
    6.     How can I get period end dates to print in reports?
    Thank you to anyone who can help.
    Mark Galla

    try this
    <a href="http://help.sap.com/saphelp_47x200/helpdata/en/da/6ada3889432f48e10000000a114084/frameset.htm">http://help.sap.com/saphelp_47x200/helpdata/en/da/6ada3889432f48e10000000a114084/frameset.htm</a>
    Thanks& Regards
    Naresh

  • Painting question

    Hello guys,
    Here is my situation:
    I have a jpanel with a plot , drawn using paintComponent() method, of some math. function.
    Now I would like to add to this panel another plot.
    Is it possible to paint just the new plot without repainting the old one ?
    If yes how ?

    I paint one plot in paintComponent() method.
    For one plot I have one ArrayList of it's points to draw.
    The thing is that I would like to add many plots to one panel.
    For example, the user pressed the button to draw the first plot.
    Then the user pressed a button to draw another plot, on the same panel,
    so both plots are visible.
    I can see one way to do it:
    I need to have a field in my class - an array X - which holds under position 0
    an ArrayList with points of plot 1 , then under position 1 there is an ArrayList with points of
    plot 2 etc. Then in paintComponent() method I have to go through
    the array X and draw all the points in every ArrayList.
    Now my question is : can the same result be done in other way ? So I
    don't need to draw all the points of all plots every time the new plot is added
    but just to draw only the new plot ?
    Well I guess there isn't but just want to check if I'm right :-)
    Regards

  • Image Painting Question

    In JavaScript I was able to achieve an odometer effect by simply changing the source reference of a displayed image. Being new to Java, what is a good method to achieve this same effect in Java? Each of my digit images are stored in an array from [0] to [9] with the array position equal to the digit value. Please, no Swing or Java2 recommendations, as the applet is being compiled with target 1.1 to reach a broader viewer range.
    Below is a snipped portion of my JavaScript code as an example of what I wish to achieve in Java. In the JavaScript, a setTimeout keeps the images updated. In Java, a thread will keep the images updated. (This JavaScript version doesn't have the images stored in an array, but I don't think how the images are stored should affect the method used to paint them periodically to the screen.) Thanks!
    now = new Date();
    minute = now.getMinutes();
    if(minute < 10) {
    document.c3.src = l0.src;
    document.c4.src = eval("l"+minute+".src");
    else {
    document.c3.src = eval("l"+minute.toString().substring(0,1)+".src");
    document.c4.src = eval("l"+minute.toString().substring(1,2)+".src");
    }

    Is anybody going to reply...?

  • Digital painting question

    Making a comic. When doing a digital painting, why do people color everything in blue before coloring with other colors?

    It's a pencil sketch technique employed by old school comic artists.  It's called "non-photo" or "non-repro" blue.
    Non-photo blue is a particular shade of blue that can not be detected by graphic arts cameras. This allows layout editors to write notes to the printer on the print flat (the image that is to be photographed and sent to print) which will not show in the final form. As well as this, it allows artists to lay down sketch lines without the need to erase after inking.
    Non-photo blue - Wikipedia, the free encyclopedia
    You wouldn't think it would make it to digital, but this explains it: http://comicsaregreat.com/video-making-non-photo-blue-pencils-in-photoshop
    It's one of the Brush Tool Presets in Photoshop
    Gene

  • Cropping & Painting Question

    I'm using PE5 - I'd like to place the top border of my cropping tool/frame above my picture to be edited , having selected 4x6 format - doing this I naturally end up with white space at the top of my final 4x6 print - since the top of the picture is blue sky, is there a way to "paint" this space blue thereby cropping where I want and keeping the picture in the original proportions ?

    If the sky is a uniform blue across the image, you could use the eyedropper to sample the color. After you do your 'crop', create a new layer under the current image and fill it with the sampled blue. You may need to add some noise to match the texture of the original.
    You should note that skies are rarely completely uniform -- you might have to blend samples from different areas, use a gradient, feather the join between the original and the fill or some combination of these.
    Bob Warren

  • Report painter question regarding amounts in different currencies

    Hi,
    I have a report created in GRR2 using library 1VK. We display the total costs SWOG here but have the request to see in addition these costs in USD simulteanously. For that I included the basic key figure SWZG. When executing the report there is now a new selection parameter Target currency, Exchange rate date and Exchange rate type. I can see a new column with USD values, so far so good. But when I check the calculation I find that it can't be right, it differs from what it should calculate.
    If I execute the report and select currency tranlsation of the key figure SWOG with exactly the same exchange parameters as above I'm getting different values in USD which match my manual calculation.
    Any idea why this happens? What do you recommend to have both currencies ate the same time on the screen?
    Thank you
    Exberliner

    hii sanjeev.
    try this,
    FM - > spell_amount
    OR
    data: words(50) type c.
    call function 'HR_IN_CHG_INR_WRDS'
         exporting
              amt_in_num   = '100000'
         importing
              amt_in_words = words.
    write:/ words.
    OR
    RF_SPELL
    rgds
    anver

  • Report painter question

    Hi
    In our old reports , when I  double click the column (GRR2), I see a pop up for selecting the characteristics’ see some characteristics attached to the column. The mystery to me is there "Record Type" char is selected twice and have different values. While I make new column, I am unable to select the record type char twice . I don't see the copy function either in that pop up. Can some one help me how to select record type twice ? Or have you seen selecting any char twice and give different values to it.Thanks
    Satya

    Scroll to the right, you may find a right arrow click on that to have record type in the next line as well.
    This while you are in the column double clicked and you see the characteristics.

  • Process industry  issue

    Dear all,
    For PP_PI industry (Paint)
    Question-
    1) How to map the process loss.
    2) Suppose we r manufatured paint A and because of quality its consider as a  paint B . How i can map?
    3)Suppose we r manufactured paint A, because of quality it is not ok and same batch use partially at the time of creation next batch of same painr A
    How can i map this also?
    Kindly help

    Hi Harish,
    1) How to map the process loss. -
    What you can do is suppose you had a order qty of 100. Do the picking for 100 so will have a track that you had issued full order qty. Now at the time of confirmation you confirm you YIELD say 90 & 10 as a scrap.
    2) Suppose we r manufatured paint A and because of quality its consider as a paint B . How i can map?
    Here at the time of giving UD can transfer the stock to new maerial. You can check this out in quality stock posting screen.
    3)3)Suppose we r manufactured paint A, because of quality it is not ok and same batch use partially at the time of creation next batch of same painr A
    Mainiting the recurcive bom for this and add material A in BOM A.
    Hope it will help you.
    Regards
    Abhijit Gautam

  • I have a question about General Data Selection in Report Painter

    Please help me out. Thi is the question....here it goes.
    In a Report in ReportPainter, I have in the General Data Selection the following selected characteristics. They are:
    Ledger = 0
    Record Type = 0
    Version = 1
    Fiscal Year = Z-ANOACT
    Period = (1CPERIV, 1CPERIB)
    So that we have the next screen in the Report’s execution.
    Fiscal Year : 2006
    From Period : 1
    To Period : 12
    Note:
    *Z-ANOACT = Variable so that with a user-exit calculates the actual year. Right now is 2006.
    *1CPERIV = This From-Period Variable is referenced to CCSS Table and PERBL Field Name. Its default value is 1.
    *1CPERIB = This To-Period Variable is referenced to CCSS Table and PERBL Field Name.
    Its default value is 12. Rigth now, we are in the fiscal month 5 (November).
    Id like to filtrate information from January,2006,Period:07 to November,2007,Period:05.
    I mean I work with the fiscal calendar because the information to get from the table is saved due to this calendar.
    The Fiscal Calendar is from July to June:
    Month          Period     Year
    January          07     2006     
    February     08     2006
    March          09     2006
    April          10     2006     
    May          11     2006                   
    June          12     2006
    July          01     2007
    Augost          02     2007
    September     03     2007     
    October          04     2007
    November     05     2007
    December      06     2007
    Right now, we are in November , 2006 (month=11) but according to the fiscal calendar we are in November, 2007 (month=5).
    How I can accommodate my variables or what I am doing wrong so that I can select information from periods 7 to 12, 2006 ( January to June, 2006) and information from periods 1 to 5, 2007 (July to November, 2007) having the screen cited above so that report painter adds the 2 ranges.
    I cannot do it with the criteria selection cited above because I only have a year and a range of periods and my end-user doesnt want to run my report twice:
    One run with periods 7 to 12, 2006 and
    Another run with periods 1 to 5, 2007 and then to add the 2 reports in excel to form a report.
    Hed like something in my screen like this……
    Fiscal Year = 2006
    From period = 7
    To Period = 12
    Fiscal Year = 2007
    From period = 1
    To Period = 5
    And then report painter will add the 2 ranges.
    Many Thanks if you know anything that can help me, please let me know.

    Please help me out. Thi is the question....here it goes.
    In a Report in ReportPainter, I have in the General Data Selection the following selected characteristics. They are:
    Ledger = 0
    Record Type = 0
    Version = 1
    Fiscal Year = Z-ANOACT
    Period = (1CPERIV, 1CPERIB)
    So that we have the next screen in the Report’s execution.
    Fiscal Year : 2006
    From Period : 1
    To Period : 12
    Note:
    *Z-ANOACT = Variable so that with a user-exit calculates the actual year. Right now is 2006.
    *1CPERIV = This From-Period Variable is referenced to CCSS Table and PERBL Field Name. Its default value is 1.
    *1CPERIB = This To-Period Variable is referenced to CCSS Table and PERBL Field Name.
    Its default value is 12. Rigth now, we are in the fiscal month 5 (November).
    Id like to filtrate information from January,2006,Period:07 to November,2007,Period:05.
    I mean I work with the fiscal calendar because the information to get from the table is saved due to this calendar.
    The Fiscal Calendar is from July to June:
    Month          Period     Year
    January          07     2006     
    February     08     2006
    March          09     2006
    April          10     2006     
    May          11     2006                   
    June          12     2006
    July          01     2007
    Augost          02     2007
    September     03     2007     
    October          04     2007
    November     05     2007
    December      06     2007
    Right now, we are in November , 2006 (month=11) but according to the fiscal calendar we are in November, 2007 (month=5).
    How I can accommodate my variables or what I am doing wrong so that I can select information from periods 7 to 12, 2006 ( January to June, 2006) and information from periods 1 to 5, 2007 (July to November, 2007) having the screen cited above so that report painter adds the 2 ranges.
    I cannot do it with the criteria selection cited above because I only have a year and a range of periods and my end-user doesnt want to run my report twice:
    One run with periods 7 to 12, 2006 and
    Another run with periods 1 to 5, 2007 and then to add the 2 reports in excel to form a report.
    Hed like something in my screen like this……
    Fiscal Year = 2006
    From period = 7
    To Period = 12
    Fiscal Year = 2007
    From period = 1
    To Period = 5
    And then report painter will add the 2 ranges.
    Many Thanks if you know anything that can help me, please let me know.

  • I have a question to ask you about General Data Selection in Report Painter

    Please help me out. Thi is the question....here it goes.
    In a Report in ReportPainter, I have in the General Data Selection the following selected characteristics. They are:
    Ledger = 0
    Record Type = 0
    Version =  1
    Fiscal Year = Z-ANOACT
    Period = (1CPERIV, 1CPERIB)
    So that we have the next screen in the Report’s execution.
    Fiscal Year : 2006
    From Period : 1
    To Period     : 12
    Note:
    *Z-ANOACT = Variable so that with a user-exit calculates the actual year. Right now is 2006.
    *1CPERIV = This From-Period Variable is referenced to CCSS Table and PERBL Field Name. Its default value is 1.
    *1CPERIB = This To-Period Variable is referenced to CCSS Table and PERBL Field Name.
    Its default value is 12. Rigth now, we are in the fiscal month 5 (November).
    Id like to filtrate information from January (2006) to September (2007). I mean I work with the fiscal calendar because the information to get from the table is saved due to this calendar.
    The Fiscal Calendar is from July to June:
    July = 1
    August = 2
    September = 3
    June = 12
    How I can accommodate my variables or what I am doing wrong so that I can select information from periods 7 to 12, 2006 ( January to June, 2006) and information from periods 1 to 3, 2007 (July to September, 2007) having the screen cited above and having the information selected added.
    I cannot do it with the criteria selection cited above because I only have a year and a range of periods and my end-user doesnt want to run my report twice:
    One run with periods 7 to 12, 2006 and
    Another run with periods 1 to 3, 2007
    Hed like something in my screen like this……
    Fiscal Year = 2006                                                
    From period = 7
    To Period     = 12
    Fiscal Year = 2007                                                
    From period = 1
    To Period     = 3
    And to get the report added.
    Many Thanks if you know anything that can help me, please let me know.

    ABDUL: I understand the ABAP Code but the information is saved in the table according to the fiscal calendar.
    Fiscal Calendar Number of the MonthYear
    January             7                    2006
    February            8                    2006
    March               9                    2006     
    April               10                    2006
    May                 11                    2006     
    June                12                    2006
    July                1                    2007
    Augost              2                    2007
    September           3                    2007
    October             4                    2007
    November            5                    2007     
    December            6                    2007
    Normally, We are in November 2006 (month=11, year 2006).
    However, fiscally; We are November 2007 (month=5, year=2007).
    Important Notes:
    •     The information is saved according to the fiscal calendar in the table.
    •     My end-user wants to filtrate the information from January to November . I mean
    Actual Year  : 2006               Actual Year   :  2007
    From   Period:      7     AND           From    Period:      1
    To       Period:     12               To        Period:       5
    I understand you told me about the ABAP code, for example my characteristics in the general data selection are:
    Actual Year  : 2006
    From   Period: 7
    To       Period: 5   (I would have an error here because From-Period Variable is greater than To-Period Variable)
    According the ABAP code you told me, this would be:
    Actual Year  : 2006
    From   Period: 1
    To       Period: 11
    If I run the report with these last parameters you told me, report painter only would add information from year 2006 and fiscal months 1 to 11 (July to May except June).  We don’t want this, that we want is :
    Actual Year  : 2006               Actual Year   :  2007
    From   Period:      7     AND           From    Period:      1
    To       Period:     12               To        Period:       5
    How can I do this?? My email is [email protected] or [email protected]
    Right now, the end-user runs the report twice and adds the information in excel. One run for :
    Actual Year  : 2006
    From   Period:      7
    To       Period:     12
    And other run with:
    Actual Year   :  2007
    From    Period:      1
    To        Period:       5
    But the question is how you can do it with only a run and in this way:
    Actual Year  : 2006               Actual Year   :  2007
    From   Period:      7     AND           From    Period:      1
    To       Period:     12               To        Period:       5
    Thanks if someone can help me!!

  • Question about sets in report painter.

    Hi, everybody. Please, could someone help me in this matter?.
    I wanna delete a set with the GS04 transaction in Report Painter but I cannot.
    When I put the set's id (XXX) in the set's name and push Delete-Set-F8 button, I get the following error:
    The XXX set cannot be deleted.I consult the error with the help and SAP tells me that  I need to use the set-usage option to view where the set is used in the system.
    I select this set-usage option under the utilities menu and SAP tells me that the set is being used in a report.
    The thing is that the report doesnt exist. I deleted the report before. Why the error is then.
    However, I created, generated and compiled the report again in report painter with other different set so that I confirmed that the report was not using the XXX set  and the error continues with report or without it.
    That I tried to say was that the XXX set is not being used anywhere and the question then is why report painter is telling me that the set is being used in a report. Thing that is not true.
    Thanks and I hope someone can help me out!!

    Hi, everybody. Please, could someone help me in this matter?.
    I wanna delete a set with the GS04 transaction in Report Painter but I cannot.
    When I put the set's id (XXX) in the set's name and push Delete-Set-F8 button, I get the following error:
    The XXX set cannot be deleted.I consult the error with the help and SAP tells me that  I need to use the set-usage option to view where the set is used in the system.
    I select this set-usage option under the utilities menu and SAP tells me that the set is being used in a report.
    The thing is that the report doesnt exist. I deleted the report before. Why the error is then.
    However, I created, generated and compiled the report again in report painter with other different set so that I confirmed that the report was not using the XXX set  and the error continues with report or without it.
    That I tried to say was that the XXX set is not being used anywhere and the question then is why report painter is telling me that the set is being used in a report. Thing that is not true.
    Thanks and I hope someone can help me out!!

  • Graphics question. paint(), repaint(), update()

    Hi
    I have a GUI which consists of swing components and I want to paint onto them. For example if somebody select a component I want to paint a rectangle around it.
    The select event stores the component in a variable and calls repaint(). This shoul call paint() which looks like this:
    public void paint( graphics g){
    draw the rectangle
    super.paint(g);
    The rectangle is actually painted for half a second. Then it is gone again. I want to have it painted permanentely. Why is the rectangle erased after that? Is it because of the update() method?
    I tried to overwrite the update method with a plain method:
    public void update(graphics g) { }
    it didnt do anything.
    Another question. I have to paint differnt stuff regarding what events are thrown. Is it a good programming style to put all the draw stuff into the paint method and look what happend like:
    if(event a)
    else if(event b)
    ...

    Have you tried putting super.paint(g) before the code to draw the rectangle? I think what's happening is that the super's paint is drawing the component, thus erasing your rectangle.
    You may want to check the API for other options. There may be a property that indicates the size and color of a border. It would be easier and probably look better to adjust that, if it exists.
    I believe that update() draws a background (just a square of background color) and then calls paint(). If you override it with an empty method, I'd expect that nothing would be drawn.

Maybe you are looking for

  • Enlarge size of a field on screen

    Hello, I'm looking for a way to enlarge the size of a field on screen. For instance when you have the Delivery screen the field where the name of the customer is shown is quite short. When the customers name is in total 60 characters you only can vie

  • I have a problem in using  for all entries

    Hi i have a problem in using <b>for all entries</b> i have declared the two internal tables as below   DATA: BEGIN OF ITAB OCCURS 10,           EBELN LIKE EKKO-EBELN,           LIFNR LIKE EKKO-LIFNR,           EBELP LIKE EKBE-EBELP,           BELNR L

  • P6 EPPM 8.3 configuration with BI

    Hi Everyone I am having issue regarding BI and P6 configuration. Default reports are not working neither in P6 nor in BI. When I check the report in Bi the reports open blank. In P6 while running report I am getting error Errors have been encountered

  • In j1iin in balances column ECS balance is not appearing

    Hi all, In J1iin  we have balance column, in which we can see the excise balances available for BED . ECS, SECS etc., Here BED , SECS balances are seen, but ECS balance is not appearing. Please update whether any note has to be updated

  • Search help in Screen Painter

    Hi Experts, I have created a structure in which I have a Date field of type sy-datum. After putting the date field from the structure to the screen painter. When I test the screen in se51 I am getting the search help for date. But when I test thru tr