Help with grabbing additional data in report

We have today started to evaluate Crystal Reports 2008 SP3 and, using the MySQL Connector/ODBC, I'm able to generate reports based on data stored in our MySQL Server 4.0.12 database.
However, I've been asked to provide some additional information in this report, and this is where I'm struggling. What I want to do is to take a value from each record and put that into a MySQL query to grab another value to place on that line. For example, my report shows the width of a particular item, but I want to add another field in that row detail showing how many items of that width we have in stock.
What is the best way to do this? I can run a command using the Command interface and get a static value (i.e. a hard-coded WHERE clause), but I can't work out if you can reference a value on a particular row to put in the WHERE clause using this method.
Thank you in advance for your help.
Steve

Ok bear with me here and forgive any typos. I'm stuck using an iPhone on this one.
For what you're trying to do a SQL Commend is your best option.
I don't have or use any MySQL databases so my syntax may be off but I'll at least try to get the point across...
SELECT
t1.ProductName,
t1.Length,
t1.Width,
t1.Height,
t2.ProductName AS RelatedProducts
FROM (
     SELECT
     ProductName,
     Length,
     Width,
     Height
     FROM TableName
     WHERE records meet report criteria) t1
LEFT OUTER JOIN TableName t2 ON t1.Length = t2.Length
This will most likely cause a "1 to many" relationship, causing a "copy" of the t1 fields for every related product.
No problem... Just group on t1.Product and place the related products in the details.
HTH,
Jason
Edited by: Jason Long on Mar 24, 2011 12:28 PM
Rewrote SQL to prevent the WHERE clause from filtering the related products...

Similar Messages

  • Hi can you help with the following panic attack report,

    hi can you help with the following panic attack report, macbook pro OS 10.7.3
    Interval Since Last Panic Report:  157997 sec
    Panics Since Last Report:          1
    Anonymous UUID:                    7ADCF50C-CC18-405E-9D5C-03325D3A83FA
    Thu Mar 29 05:37:28 2012
    panic(cpu 0 caller 0xffffff80002c266d): Kernel trap at 0xffffff800021d905, type 14=page fault, registers:
    CR0: 0x000000008001003b, CR2: 0xffffef801a845328, CR3: 0x0000000019452019, CR4: 0x00000000000606e0
    RAX: 0xffffff801a8450d8, RBX: 0xffffff800e79f340, RCX: 0xffffff801a8450d8, RDX: 0xffffef801a8450d8
    RSP: 0xffffff80a4623e90, RBP: 0xffffff80a4623eb0, RSI: 0x0000000020c85580, RDI: 0x0000000000000001
    R8:  0xffffff80008bd890, R9:  0xffffff80058aeac8, R10: 0xfffffe80539a9928, R11: 0x0008000000053d89
    R12: 0xffffff800e79f370, R13: 0xffffff8000846288, R14: 0xffffff801a8450c0, R15: 0x0000000000000001
    RFL: 0x0000000000010206, RIP: 0xffffff800021d905, CS:  0x0000000000000008, SS:  0x0000000000000010
    CR2: 0xffffef801a845328, Error code: 0x0000000000000002, Faulting CPU: 0x0
    Backtrace (CPU 0), Frame : Return Address
    0xffffff80a4623b50 : 0xffffff8000220702
    0xffffff80a4623bd0 : 0xffffff80002c266d
    0xffffff80a4623d70 : 0xffffff80002d7a1d
    0xffffff80a4623d90 : 0xffffff800021d905
    0xffffff80a4623eb0 : 0xffffff800021daad
    0xffffff80a4623ee0 : 0xffffff800023caa9
    0xffffff80a4623f10 : 0xffffff800023cb36
    0xffffff80a4623f30 : 0xffffff80005a3258
    0xffffff80a4623f60 : 0xffffff80005ca448
    0xffffff80a4623fb0 : 0xffffff80002d7f39
    BSD process name corresponding to current thread: SophosAntiVirus
    Mac OS version:
    11D50b
    Kernel version:
    Darwin Kernel Version 11.3.0: Thu Jan 12 18:47:41 PST 2012; root:xnu-1699.24.23~1/RELEASE_X86_64
    Kernel UUID: 7B6546C7-70E8-3ED8-A6C3-C927E4D3D0D6
    System model name: MacBookPro8,3 (Mac-942459F5819B171B)
    System uptime in nanoseconds: 5720232329361
    last loaded kext at 5694112402758: com.apple.iokit.IOSCSIBlockCommandsDevice          3.0.3 (addr 0xffffff7f807a3000, size 86016)
    last unloaded kext at 248390619372: com.apple.driver.AppleUSBUHCI          4.4.5 (addr 0xffffff7f80a4e000, size 65536)
    loaded kexts:
    com.sophos.kext.sav          7.3.0
    com.apple.driver.AppleUSBCDC          4.1.15
    com.apple.driver.AppleHWSensor          1.9.4d0
    com.apple.filesystems.autofs          3.0
    com.apple.driver.AppleMikeyHIDDriver          122
    com.apple.driver.AudioAUUC          1.59
    com.apple.driver.AppleUpstreamUserClient          3.5.9
    com.apple.driver.AppleMCCSControl          1.0.26
    com.apple.driver.AppleHDA          2.1.7f9
    com.apple.driver.AppleMikeyDriver          2.1.7f9
    com.apple.driver.AppleIntelHD3000Graphics          7.1.8
    com.apple.driver.AGPM          100.12.42
    com.apple.kext.ATIFramebuffer          7.1.8
    com.apple.driver.SMCMotionSensor          3.0.1d2
    com.apple.iokit.IOUserEthernet          1.0.0d1
    com.apple.driver.AppleSMCLMU          2.0.1d2
    com.apple.Dont_Steal_Mac_OS_X          7.0.0
    com.apple.driver.AudioIPCDriver          1.2.2
    com.apple.driver.ACPI_SMC_PlatformPlugin          4.7.5d4
    com.apple.driver.AppleMuxControl          3.0.16
    com.apple.driver.AppleLPC          1.5.3
    com.apple.ATIRadeonX3000          7.1.8
    com.apple.driver.AppleUSBTCButtons          225.2
    com.apple.driver.AppleUSBTCKeyboard          225.2
    com.apple.driver.AppleIRController          312
    com.apple.AppleFSCompression.AppleFSCompressionTypeDataless          1.0.0d1
    com.apple.AppleFSCompression.AppleFSCompressionTypeZlib          1.0.0d1
    com.apple.BootCache          33
    com.apple.iokit.SCSITaskUserClient          3.0.3
    com.apple.iokit.IOAHCIBlockStorage          2.0.1
    com.apple.driver.AppleUSBHub          4.5.0
    com.apple.driver.AppleFWOHCI          4.8.9
    com.apple.driver.AirPort.Brcm4331          513.20.19
    com.apple.iokit.AppleBCM5701Ethernet          3.0.8b2
    com.apple.driver.AppleEFINVRAM          1.5.0
    com.apple.driver.AppleAHCIPort          2.2.0
    com.apple.driver.AppleSmartBatteryManager          161.0.0
    com.apple.driver.AppleUSBEHCI          4.5.8
    com.apple.driver.AppleACPIButtons          1.4
    com.apple.driver.AppleRTC          1.4
    com.apple.driver.AppleHPET          1.6
    com.apple.driver.AppleSMBIOS          1.7
    com.apple.driver.AppleACPIEC          1.4
    com.apple.driver.AppleAPIC          1.5
    com.apple.driver.AppleIntelCPUPowerManagementClient          167.3.0
    com.apple.nke.applicationfirewall          3.2.30
    com.apple.security.quarantine          1.1
    com.apple.driver.AppleIntelCPUPowerManagement          167.3.0
    com.apple.iokit.IOSCSIBlockCommandsDevice          3.0.3
    com.apple.iokit.IOUSBMassStorageClass          3.0.1
    com.apple.kext.triggers          1.0
    com.apple.driver.AppleAVBAudio          1.0.0d11
    com.apple.driver.DspFuncLib          2.1.7f9
    com.apple.driver.AppleSMBusController          1.0.10d0
    com.apple.iokit.IOSurface          80.0
    com.apple.iokit.IOFireWireIP          2.2.4
    com.apple.iokit.IOBluetoothSerialManager          4.0.3f12
    com.apple.iokit.IOSerialFamily          10.0.5
    com.apple.iokit.IOAVBFamily          1.0.0d22
    com.apple.driver.AppleHDAController          2.1.7f9
    com.apple.iokit.IOHDAFamily          2.1.7f9
    com.apple.iokit.IOAudioFamily          1.8.6fc6
    com.apple.kext.OSvKernDSPLib          1.3
    com.apple.driver.ApplePolicyControl          3.0.16
    com.apple.driver.AppleSMC          3.1.1d8
    com.apple.driver.IOPlatformPluginFamily          4.7.5d4
    com.apple.driver.AppleSMBusPCI          1.0.10d0
    com.apple.driver.AppleGraphicsControl          3.0.16
    com.apple.driver.AppleBacklightExpert          1.0.3
    com.apple.iokit.IONDRVSupport          2.3.2
    com.apple.kext.ATI6000Controller          7.1.8
    com.apple.kext.ATISupport          7.1.8
    com.apple.driver.AppleIntelSNBGraphicsFB          7.1.8
    com.apple.iokit.IOGraphicsFamily          2.3.2
    com.apple.driver.BroadcomUSBBluetoothHCIController          4.0.3f12
    com.apple.driver.AppleUSBBluetoothHCIController          4.0.3f12
    com.apple.iokit.IOBluetoothFamily          4.0.3f12
    com.apple.driver.AppleThunderboltDPInAdapter          1.5.9
    com.apple.driver.AppleThunderboltDPAdapterFamily          1.5.9
    com.apple.driver.AppleThunderboltPCIDownAdapter          1.2.1
    com.apple.driver.AppleUSBMultitouch          227.1
    com.apple.iokit.IOUSBHIDDriver          4.4.5
    com.apple.driver.AppleUSBMergeNub          4.5.3
    com.apple.driver.AppleUSBComposite          4.5.8
    com.apple.iokit.IOSCSIMultimediaCommandsDevice          3.0.3
    com.apple.iokit.IOBDStorageFamily          1.6
    com.apple.iokit.IODVDStorageFamily          1.7
    com.apple.iokit.IOCDStorageFamily          1.7
    com.apple.driver.XsanFilter          403
    com.apple.iokit.IOAHCISerialATAPI          2.0.1
    com.apple.iokit.IOSCSIArchitectureModelFamily          3.0.3
    com.apple.driver.AppleThunderboltNHI          1.3.2
    com.apple.iokit.IOThunderboltFamily          1.7.4
    com.apple.iokit.IOUSBUserClient          4.5.8
    com.apple.iokit.IOFireWireFamily          4.4.5
    com.apple.iokit.IO80211Family          412.2
    com.apple.iokit.IOEthernetAVBController          1.0.0d5
    com.apple.iokit.IONetworkingFamily          2.0
    com.apple.iokit.IOAHCIFamily          2.0.7
    com.apple.iokit.IOUSBFamily          4.5.8
    com.apple.driver.AppleEFIRuntime          1.5.0
    com.apple.iokit.IOHIDFamily          1.7.1
    com.apple.iokit.IOSMBusFamily          1.1
    com.apple.security.sandbox          177.3
    com.apple.kext.AppleMatch          1.0.0d1
    com.apple.security.TMSafetyNet          7
    com.apple.driver.DiskImages          331.3
    com.apple.iokit.IOStorageFamily          1.7
    com.apple.driver.AppleKeyStore          28.18
    com.apple.driver.AppleACPIPlatform          1.4
    com.apple.iokit.IOPCIFamily          2.6.8
    com.apple.iokit.IOACPIFamily          1.4
    Model: MacBookPro8,3, BootROM MBP81.0047.B27, 4 processors, Intel Core i7, 2.2 GHz, 4 GB, SMC 1.70f5
    Graphics: AMD Radeon HD 6750M, AMD Radeon HD 6750M, PCIe, 1024 MB
    Graphics: Intel HD Graphics 3000, Intel HD Graphics 3000, Built-In, 384 MB
    Memory Module: BANK 0/DIMM0, 2 GB, DDR3, 1333 MHz, 0x80AD, 0x484D54333235533642465238432D48392020
    Memory Module: BANK 1/DIMM0, 2 GB, DDR3, 1333 MHz, 0x80AD, 0x484D54333235533642465238432D48392020
    AirPort: spairport_wireless_card_type_airport_extreme (0x14E4, 0xD6), Broadcom BCM43xx 1.0 (5.100.98.75.19)
    Bluetooth: Version 4.0.3f12, 2 service, 18 devices, 2 incoming serial ports
    Network Service: AirPort, AirPort, en1
    Serial ATA Device: TOSHIBA MK7559GSXF, 750.16 GB
    Serial ATA Device: MATSHITADVD-R   UJ-898
    USB Device: FaceTime HD Camera (Built-in), apple_vendor_id, 0x8509, 0xfa200000 / 3
    USB Device: hub_device, 0x0424  (SMSC), 0x2514, 0xfa100000 / 2
    USB Device: BRCM2070 Hub, 0x0a5c  (Broadcom Corp.), 0x4500, 0xfa110000 / 5
    USB Device: Bluetooth USB Host Controller, apple_vendor_id, 0x821a, 0xfa113000 / 8
    USB Device: Apple Internal Keyboard / Trackpad, apple_vendor_id, 0x0245, 0xfa120000 / 4
    USB Device: hub_device, 0x0424  (SMSC), 0x2514, 0xfd100000 / 2
    USB Device: IR Receiver, apple_vendor_id, 0x8242, 0xfd110000 / 3

    Get rid of Sophos Anti-Virus software you have installed. Use the uninstaller or:
    Uninstalling Software: The Basics
    Most OS X applications are completely self-contained "packages" that can be uninstalled by simply dragging the application to the Trash.  Applications may create preference files that are stored in the /Home/Library/Preferences/ folder.  Although they do nothing once you delete the associated application, they do take up some disk space.  If you want you can look for them in the above location and delete them, too.
    Some applications may install an uninstaller program that can be used to remove the application.  In some cases the uninstaller may be part of the application's installer, and is invoked by clicking on a Customize button that will appear during the install process.
    Some applications may install components in the /Home/Library/Applications Support/ folder.  You can also check there to see if the application has created a folder.  You can also delete the folder that's in the Applications Support folder.  Again, they don't do anything but take up disk space once the application is trashed.
    Some applications may install a startupitem or a Log In item.  Startupitems are usually installed in the /Library/StartupItems/ folder and less often in the /Home/Library/StartupItems/ folder.  Log In Items are set in the Accounts preferences.  Open System Preferences, click on the Accounts icon, then click on the LogIn Items tab.  Locate the item in the list for the application you want to remove and click on the "-" button to delete it from the list.
    Some software use startup daemons or agents that are a new feature of the OS.  Look for them in /Library/LaunchAgents/ and /Library/LaunchDaemons/ or in /Home/Library/LaunchAgents/.
    If an application installs any other files the best way to track them down is to do a Finder search using the application name or the developer name as the search term.  Unfortunately Spotlight will not look in certain folders by default.  You can modify Spotlight's behavior or use a third-party search utility, Easy Find, instead.  Download Easy Find at VersionTracker or MacUpdate.
    Some applications install a receipt in the /Library/Receipts/ folder.  Usually with the same name as the program or the developer.  The item generally has a ".pkg" extension.  Be sure you also delete this item as some programs use it to determine if it's already installed.
    There are many utilities that can uninstall applications.  Here is a selection:
    AppZapper
    Automaton
    Hazel
    CleanApp
    Yank
    SuperPop
    Uninstaller
    Spring Cleaning
    Look for them at VersionTracker or MacUpdate.
    For more information visit The XLab FAQs and read the FAQ on removing software.

  • Help with excel grouped data and sorting to keep data intact

    I have a master spreadsheet with lots of data. I am trying to grouped the data based on physical address/city, add the values and once done sort it by valuation based on descending order by valuation but my data keep messing up.
    So in Row 1/col A: Address 1; Col B City: XXX; Col C: Valuation $$$
    Row 2/col A: Address 1; Col B City: XXX; Col C: Vauation $$$
    Row 3/col A: Address 2; COl B City: YYY; Col C:  Valuation $$$
    SO I sort by city and in ROw 1/2 same city with same address, I grouped it.  THen I created a new row below Row 3 and add up the grouped data (i.e. ROw 1 and 2).  I go through the entire list to finalize the grouped locations.  
    But when I am done and I sort by Valuation, all my data messed up coz I created a new row with addition of grouped location valuation and the formula gets messed up.
    Any one with ideas please help.  My deadline for this project is just a week away and I am freaking out.
    THanks in advance.

    it seems upload a sample is more clearly about the required.
    KR

  • Help with XML, display data on swipe/click

    Hello.
    I am trying to create a moibile app that displays XML data. It's basically a phone book. I want the data to change when swiped. I can get the data in just fine. I can get it to display fine. I am not seeing the correct image first, however. I think it's a problem with my imagenum variable.
    Then, I want to change what is displayed when the user clicks/swipes on the screen. How do I do that?
    stop();
    var nameArray:Array = new Array();
    var countryArray:Array = new Array();
    var portraitArray:Array = new Array();
    var flagArray:Array = new Array();
    var jobtitleArray:Array = new Array();
    var imageNum:Number=0;
    var totalImages:Number;
    //Load XML
    var XMLURLLoader:URLLoader = new URLLoader();
    XMLURLLoader.load(new URLRequest("recbook.xml"));
    XMLURLLoader.addEventListener(Event.COMPLETE, processXML);
    function processXML(event:Event):void {
    var theXMLData:XML = new XML(XMLURLLoader.data);
    totalImages=theXMLData.name.length();
    for (var i:Number =0; i < totalImages; i++){
      //push xml data into the arrays
      nameArray.push(theXMLData.name[i]);
      countryArray.push(theXMLData.country[i]);
      portraitArray.push(theXMLData.portrait[i]);
      flagArray.push(theXMLData.flag[i]);
      jobtitleArray.push(theXMLData.jobtitle[i]);
    //data is processed
    loadData();
    function loadData():void {
    var thisPortrait:String = portraitArray[imageNum];
    var thisCountry:String = countryArray[imageNum];
    var thisName:String = nameArray[imageNum];
    var thisJobtitle:String = jobtitleArray[imageNum];
    var thisFlag:String = flagArray[imageNum];
    var dataLoader:Loader = new Loader();
    dataLoader.load(new URLRequest(portraitArray[imageNum]));
    dataLoader.contentLoaderInfo.addEventListener(Event.COMPLETE, dataLoaded);
    function dataLoaded(event:Event):void {
      //I want to start with image 0 (img1.jpg) and cycle through with a mouse click (finger swipe on iOS)
      stage.addEventListener(MouseEvent.CLICK, loadMainImage1);
      function loadMainImage1(event:MouseEvent):void {
       portraitUILoader.source=thisPortrait;
       flagUILoader.source=thisFlag;
       selectedName.text=thisName;
       selectedCountry.text=thisCountry;
       selectedJobtitle.text=thisJobtitle;
    //add to imageNum (1);
    imageNum++;
    if (imageNum < totalImages) {//stopping at img2
      trace("imageNum " + imageNum);
      trace("image name (thisPortrait) " + thisPortrait);//losing image 4 somewhere
      loadData();
      trace("Total Images " + totalImages);
    //click to move past the home screenI'd like to ditch this. don't know how.
    homeScreen_mc.addEventListener(MouseEvent.CLICK, goNext);
    function goNext(event:MouseEvent):void
    nextFrame();
    */here's the output:
    imageNum 1
    image name (thisPortrait) images/img1.jpg
    imageNum 2
    image name (thisPortrait) images/img2.jpg
    imageNum 3
    image name (thisPortrait) images/img3.jpg
    Total Images 4
    Total Images 4
    Total Images 4
    Total Images 4
    It starts the display on image 1 (the second in the series img2.jpg)*/

    Thank you.
    That helped. I get the correct images in the output, but not in the display. I also get the following error. Any chance you could help with that?
    new output after moving the increment:
    imageNum 0
    image name (thisPortrait) images/img1.jpg
    imageNum 1
    image name (thisPortrait) images/img2.jpg
    imageNum 2
    image name (thisPortrait) images/img3.jpg
    imageNum 3
    image name (thisPortrait) images/img4.jpg
    TypeError: Error #2007: Parameter url must be non-null.
    at flash.display::Loader/_load()
    at flash.display::Loader/load()
    at iOS_fla::MainTimeline/loadData()
    at iOS_fla::MainTimeline/loadData()
    at iOS_fla::MainTimeline/loadData()
    at iOS_fla::MainTimeline/loadData()
    at iOS_fla::MainTimeline/loadData()
    at iOS_fla::MainTimeline/processXML()
    at flash.events::EventDispatcher/dispatchEventFunction()
    at flash.events::EventDispatcher/dispatchEvent()
    at flash.net::URLLoader/onComplete()

  • Little help with FORM POST data not in UTF-8 (JSP/servlet)

    Hello,
    I am trying to update a MySQL database record with UTF-8 characters with my JSP application.
    1) I have MySQL correctly configured to handle UTF8 and have tested insert/update/select with UTF8 characters
    2) I have an "editRecord.jsp" page. At the top of the page, I specify:
    <% request.setCharacterEncoding("UTF-8"); %>
    3) I have an input form which is specified in that page which follows:
    <form action="<c:url value="/updateRecord.jsp"/>"
    name="updatetForm" method="post"
    ACCEPT-CHARSET="UTF-8"
    enctype="multipart/form-data">
    4) I have a servlet filter that takes every HttpServletRequest and modifies that object in
    doFilter(...){
    request.setCharacterEncoding("UTF-8");
    chain.doFilter(...)
    5) In updateRecord.jsp, I fill a JavaBean with the form data. Here's an example of the form input:
    name = Company
    Comments=Here's some unicode text: "&#1610;&#1606;&#1610; &#1573;&#1606; &#1576;&#1604;&#1575;&#1583;&#1607; &#1605;
    6) When I put a breakpoint and inspect the contents of the UpdateBean after posting the form, running the request through the filter, I see
    I see:
    name = Company
    Comments=Here's some unicode text: &#132;������...."
    Where could I possibly be missing something to force UTF8 encoding of these values?

    If you have to use the following code to fix the encoding:
    String value = new String(item.getString().getBytes("ISO-8859-1"), "UTF-8"); ...
    then you are just putting a band aid on something that is broken somewhere else (since this code creates a byte array in 8859-1 and then creates a string from that byte array, but assuming that the array is encoded in UTF-8). That will only work if the string you start out with is mangled.
    In many cases such a fix will actually "work" (in the sense that you may end up with something that is correctly encoded in the end), but you run the risk of breaking if the source of the original corruption is removed.

  • Need help with grabbing pixels

    import java.awt.*;
    import java.awt.image.*;
    public class pixtest extends java.applet.Applet
         Image ball;
         Image img;
         int pixels[];
         int w,h;
         MediaTracker MT;
         PixelGrabber PG;
         public void init()
              MediaTracker MT = new MediaTracker(this);
              ball = getImage(getCodeBase(), "bball.gif");
              MT.addImage(ball,0);
              try {
              MT.waitForID(0);
              } catch( InterruptedException e) {}
              int w = ball.getWidth(this);
              int h = ball.getHeight(this);
              System.out.println(w);
    //this returns a working value, it was 64
              int[] pixels = new int[w * h];
              PixelGrabber pg=new PixelGrabber(ball,0,0,w,h,pixels,0,w);
              try
              pg.grabPixels();
              catch (InterruptedException e) {}
              System.out.println(pixels[1]);
    //this returns a value of -1... and so does every other element of the array. so its null?...     
              Image img = createImage(new MemoryImageSource(w, h, pixels, 0, w))
         public void paint(Graphics g)
              g.drawImage(img,0,0,this);
    //returns java.lang.Nullpointerexception errors probably because the image is empty?
    can anyone help with this? is the pixelgrabber not working? im currently using jdk1.3.1

    Try this, (notice the changes).
    import java.awt.*;
    import java.awt.image.*;
    public class pixtest extends java.applet.Applet
         Image img;
    public void init()
         MediaTracker MT = new MediaTracker(this);
         Image ball = getImage(getCodeBase(), "bball.gif");
         MT.addImage(ball,0);
         try
              MT.waitForID(0);
         catch( InterruptedException e) {}
         int w = ball.getWidth(this);
         int h = ball.getHeight(this);
         int[] pixels = new int[w * h];
         PixelGrabber pg=new PixelGrabber(ball,0,0,w,h,pixels,0,w);
         try
              pg.grabPixels();
         catch (InterruptedException e) {}
         img = createImage(new MemoryImageSource(w, h, pixels, 0, w));
    public void paint(Graphics g)
         g.drawImage(img,0,0,this);
    Noah
    import java.awt.*;
    import java.awt.image.*;
    public class pixtest extends java.applet.Applet
         Image img;
    public void init()
         MediaTracker MT = new MediaTracker(this);
         Image ball = getImage(getCodeBase(), "home24.gif");
         MT.addImage(ball,0);
         try
              MT.waitForID(0);
         catch( InterruptedException e) {}
         int w = ball.getWidth(this);
         int h = ball.getHeight(this);
         int[] pixels = new int[w * h];
         PixelGrabber pg=new PixelGrabber(ball,0,0,w,h,pixels,0,w);
         try
              pg.grabPixels();
         catch (InterruptedException e) {}
         img = createImage(new MemoryImageSource(w, h, pixels, 0, w));
    public void paint(Graphics g)
         g.drawImage(img,0,0,this);

  • Help with formatting for Cross Tab Report Crystal 2008

    This is probably a simple question.  I have a cross tab report that displays sales by month for a period of 6 months.  These sales columns are formatted to be numbers with no decimals.  In addition to these columns, I have inserted columns that display the percentage up/down in sales over the previous month.  If I try to format the percentage columns, it changes every column to then display "##,##.##%" when I need to keep the sales columns at "##,###" with no decimal or percentage sign.
    1.  Is there a way to change the formatting of some of the columns but not all in a cross tab report?
    2.  If not, can I add a function that would change these in the calculation formula of the calculated member? 
    I tried to add "%" but it wants it to return a number.
    Here is the current code:
    //The calculation formula is used in place of the summaries in Calculated Members.
    // This calculation formula must return a/an Number value.
    If GridValueAt (CurrentRowIndex,CurrentColumnIndex-3,CurrentSummaryIndex) = 0 then 0 else
    ((GridValueAt (CurrentRowIndex,CurrentColumnIndex-1,CurrentSummaryIndex) -
    GridValueAt (CurrentRowIndex,CurrentColumnIndex-3,CurrentSummaryIndex)) /
    GridValueAt (CurrentRowIndex,CurrentColumnIndex-3,CurrentSummaryIndex)) * 100
    Any help is appreciated. 
    Thank you,
    Tobi

    Carl,
    Thank you for your help.  I did try your method but still couldn't get it to ignore the fact that it wanted a number.  I changed my approach a litte and managed to solve the problem.  Here is the method that I chose which managed to solve the problem.  If this is a poor way to solve it, please let me know as I am always open for new ways.
    Format Field > Number Tab > Customize > Currency  Symbol Tab
    Checked Enable Currency Symbol Fixed, changed  currency symbol to %.  This is the same thing that I did before which changes it for all columns. 
    Beside Enable Currency checkbox, I added this formula:
    // This conditional formatting formula must return one of the following Currency Symbol Constants:
    // crNoCurrencySymbol
    // crFixedCurrencySymbol
    // crFloatingCurrencySymbol
    If GridRowColumnValue("InvoiceLine.TxnDate") = Date(0,0,0) then
        crFixedCurrencySymbol  
    else
        crNoCurrencySymbol
    My added columns have a null date field so they take the currency format.  My other columns do not so they do not take the formatting.
    Thanks again for the help.
    Tobi
    Edited by: Tobi@TABeverage on Dec 2, 2009 3:58 PM

  • Need help with Monthly Transaction By Hour Report

    Post Author: cbcombs
    CA Forum: General
    Hello,Newbie needs to write a transaction report that is grouped by days of the week for a calendar month. It will have one column for each day of the week and each of those columns will contain a whole months of week day data. Then it will be grouped by each hour of the day. It will contain the number of transactions for each hour. And then a weekly average of the number of transactions for each hour of the day. The week starts on a Monday and goes through Sunday. They are probably going to want the dollar amount of the transactions too. Below is an example with the first two rows of data populated. Monthly Transaction Report For August 2007                   Mon            Tue             Wed             Thu            Fri             Sat             Sun            Average08:00                0                2               2                1                10                    5                    2                      3.1409:00                    25                    3                    5                    4                  5                    8                    6                      4.43  10:00                    5011:00                  10012:00                 15013:00                  15013:00                   12514:00                  10015:00                    5016:00                     1017:00                       2 Any help would be appreciated. 

    Post Author: kbrinton
    CA Forum: General
    You could use the cross tab expert and set the columns to the day and the row to hours with it summing your transactions. So for the rows choose your date field and then choose Group options and have it set to "for each hour". Then the column choose your date field and have it set to "for each day".  Then have it summarize your transactions.
    Hope this helps!!

  • Little help with complex XML data as data provider for chart and adg

    Hi all,
    I've been trying to think through a problem and Im hoping for
    a little help. Here's the scenario:
    I have complex nested XML data that is wrapped by subsequent
    groupings for efficiency, but I need to determine if each inner
    item belongs in the data collection for view in a data grid and
    charts.
    I've posted an example at the bottom.
    So the goal here is to first be able to select a single
    inspector and then chart out their reports. I can get the data to
    filter from the XMLListCollection using a filter on the first layer
    (ie the name of the inspector) but then can't get a filter to go
    deeper into the structure in order to determine if the individual
    item should be contained inside the collection. In other words, I
    want to filter by inspector, then time and then tag name in order
    to be able to use this data as the basis for individual series
    inside my advanced data grid and column chart.
    I've made it work with creating a new collection and then
    looping through each time there is a change to the original
    collection and updating the new collection, but that just feels so
    bloated and inefficient. The user is going to have some buttons to
    allow them to change their view. I'm wondering if there is a
    cleaner way to approach this? I even tried chaining filter
    functions together, but that didn't work cause the collection is
    reset whenever the .refresh() is called.
    If anyone has experience in efficiently dealing with complex
    XML for charting purposes and tabular display purposes, I would
    greatly appreciate your assistance. I know I can get this to work
    with a bunch of overhead, but I'm seeking something elegant.
    Thank you.

    Hi,
    Please use the code similar to below:
    SELECT * FROM DO_NOT_LOAD INTO TABLE IT_DO_NOT_LOAD.
    SORT IT_DO_NOT_LOAD by WBS_Key.
        IF SOURCE_PACKAGE IS NOT INITIAL.
          IT_SOURCE_PACKAGE[] = SOURCE_PACKAGE[].
    LOOP AT IT_SOURCE_PACKAGE INTO WA_SOURCE_PACKAGE.
            V_SYTABIX = SY-TABIX.
            READ TABLE IT_DO_NOT_LOAD into WA_DO_NOT_LOAD
            WITH KEY WBS_Key = WA_SOURCE_PACKAGE-WBS_Key
            BINARY SEARCH.
            IF SY-SUBRC = 0.
              IF ( WA_DO_NOT_LOAD-WBS_EXT = 'A' or WA_DO_NOT_LOAD-WBS_EXT = 'B' )     
              DELETE IT_SOURCE_PACKAGE INDEX V_SYTABIX.
            ENDIF.
    ENDIF.
          ENDLOOP.
          SOURCE_PACKAGE[] = IT_SOURCE_PACKAGE[].
        ENDIF.
    -Vikram

  • Looking for a specific iphone app - it is supposed to help with identifying/transferring data to purchased itunes files

    I had to get my iPhone 5c fixed today because there was a problem with syncing itunes files from my laptop; I changed the names of some of the song files/artists from my laptop and attempted to sync it to my iphone, but that created a corruption in the process, which in turn ceased any kind of syncing altogether. So my iphone is restored/fixed, but I still have to deal with having itunes purchases and old CD data listed as "Various Artists" or "Unknown Artist."
    The Mac employer who helped me told me about an app that can identify those "Unknown Artist" files and interpret the data so that the iphone can recognize it. I know that's kind of a conveluted description, but he basically said that I can type in the name of an album, and the app will identify the relevent artist name/album artwork (within a database of music info, i'm guessing) and send it over to itunes.
    I can't for the life of me remember the name of the app, but I know it starts with an S, and the app icon has the color red. I searched the music apps, but I can't seem to find it, so i'm guessing it's under a different category.
    Does anybody know the app that i'm talking about?

    The outer brown outline is just the background from the website I saw this on.  Only look at the white frame.  Then you can see the black frame around the photo.  Please help!!

  • Requesting help with a time/date synchronization problem--thanks

    I'm having a bear of a time trying to get my desktop outlook to synchronize with my 8820 blackberry. Running XP and Outlook from Office 03.  Date/time show correct on my desktop and on the device but, every time I synchronize, the calendar seems to get messed up with hour shifts on different entries. Sometimes I can see a time appear on the "details" screen when I'm synchronizing that is an hour off from the time that is on the device?  Any ideas? Many thanks.

    Sorry--meant to also say that I had reviewed the most recent similar thread on this.  In addition to both the PC and device having the right time, I did confirm both are set to the same time zone.  Really stumped on this one--thanks again.

  • Help with pnpce logic data base

    Hallow I doing a program that use logic data base pnpce(my first time) and in the program I use get peras to bring the employee num and in the loop the name of employee
    Something I doing wrong because its not working what?
    I just wont to bring to my table person_tab employee num and name.
    thankes
    Tables :pernr
    Nodes:persa
    Infotypes:0000 like t_oooo,
    00002 like t_0002.
    START-OF-SELECTION.
    GET peras.
    LOOP AT t_0000.
    MOVE t_0000-pernr TO person_tab-objid.
    APPEND person_tab.
    Endloop.
    Loop at t0002.
    MOVE t_0002-nachn TO person_tab-lastname.
    MOVE t_0002-vorna TO person_tab-firstname.
    APPEND person_tab.
    ENDLOOP.
    END-OF-SELECTION.

    Hi there. I'm not sure what version you are on, but in ERP 2005 this is an obsolete statement.  Here's an alternate way to get the information you're looking for:
    TABLES: PERNR.
    INFOTYPES: 0002.
    DATA: BEGIN OF person_tab OCCURS 0,
           objid LIKE PERNR-PERNR,
           lastname LIKE P0002-NACHN,
           firstname LIKE P0002-VORNA,
    END OF person_tab.
    START-OF-SELECTION.
    GET pernr.
    person_tab-objid = pernr-pernr.
    RP-PROVIDE-FROM-LAST P0002 space sy-datum sy-datum.
    person_tab-lastname = p0002-nachn.
    person_tab-firstname = p0002-vorna.
    APPEND person_tab.
    CLEAR person_tab.
    END-OF-SELECTION.
    Even if you don't end up using this code, you would need to change yours so that you aren't appending to your person_tab table until you have moved all of the data for the fields of your record. By appending twice like you currently are doing, you are creating two separate records (one with just the pernr and another with the first and last name).  I hope this helps.
    - April King

  • Help with setting up date and timer on flash

    anyone please help me out how to setup the date and
    timer on a flash. i tould be appreciate with this.

    kicon wrote:
    >
    anyone please help me out how to setup the date and
    timer on a flash. i tould be appreciate with this.
    a bit too general, what kind of timer ?
    Regards
    Urami
    Happy New Year guys - all the best there is in the 2006
    <urami>
    http://www.Flashfugitive.com
    </urami>
    <web junk free>
    http://www.firefox.com
    </web junk free>

  • Help with adding additional image in php

    Php coding help needed
    Hello
    I need some help in changing 2 php files so that I can grab
    the first image from an xml file.
    At the moment ..the xml has an image category called
    <UserLogo>img/IMG_1197.JPG</UserLogo>
    I want to add this USERLOGO portion in the 2 php files ..but
    do not know how to change the code. On the webpage in question,
    because the USERLOGO is not incorporated in the php files ..a
    default image currently shows up on the page:
    At the moment there are USERLOGO1 2 3 4 AND 5 Coding in the
    php files but I would like to add USERLOGO to the mix
    I have coding for the 2 php files currently in use
    xml_common.php and xml_functionsheadlines.php which are used to
    grab the xml.
    any help would be greatly appreciated ..thanks Rob

    A RED curtain? Wow, they really didn't want to make this easy, did they. There is a lot to making a good difference matte, it's no easy task. My suggestion is, get a book on compositing, watch Lynda.com tutorials, do whatever you have to to learn how to do it right, and then charge a lot of money for it. My view on people hiring students to do this kind of work is that they figure they can get you while you're green and don't know what the job is worth. They can't afford a professional who charges accordingly.
    Kudos to you for getting the gig, but don't let them get away with having you do a ton of work for peanuts, or even worse, for free.

  • Help with calculating expiration date

    Hi Microsoft Access community.
    I am trying to automatically set the expiration date in my table each time new data is entered which is +10 months -1 Day. My field name is called 'Best Before Date:', Data Type is called Date/Time, Format is set to 'Short Date' and under the Default
    Value field property I have two expressions I am trying to input.
    =DateAdd("m",10,Date())
    =DateAdd("y",-1,Date())
    These expressions work for me only when they are input separately. My issue is that I want to combine these two expressions but I don't know how.
    If anyone has any ideas of how to accomplish this task best please do help.
    Thanks
    sNiPel2

    They'll help you over here.
    http://answers.microsoft.com/en-us/office/forum/access?sort=lastreplydate&dir=desc&tab=Threads&status=&mod=&modAge=&advFil=&postedAfter=&postedBefore=&threadType=All&tm=1426425719481
    Regards, Dave Patrick ....
    Microsoft Certified Professional
    Microsoft MVP [Windows]
    Disclaimer: This posting is provided "AS IS" with no warranties or guarantees , and confers no rights.

Maybe you are looking for

  • Iphoto problem with software

    ok, new to mac...be patient!! lost my iphoto icon off of my dock. tried to find it and in the process lost my iphoto folder in picures. started a new iphoto, thinking it would restore...not. now i have 2 iphotos when i do a search. one has my photos

  • Process(m000) creation failed

    PROD DB 10.2.0.4 I got below error in the alert log file. For your information there are two databases which are interconnected and the data are transferring from each other using RIB . Error: DISTRIB TRAN 1dcd3.1053272173A4626D6C5C67083439F0BB17101B

  • Urgent : Performance Issue DELETE , INSERT INTO SELECT, UPDATE

    Hi, NEED ASSISTANCE TO OPTIMIZE THE INSERT STATEMENT (insert into select): ================================================= We have a report. As per current design following steps are used to populate the custom table whcih is used for reporting pur

  • Book color in .chm help

    Does anyone know if there's a way to change the book color in .chm help? I see where you can select a custom image. But I don't want a single image. I want to use the open books, closed books, and topic icons, just in a different color.

  • Lightroom installs to default location despite specific install location set in application manager.

    Lightroom keeps installing to the default install location even though I have a specific install location set in the application manager. Is there a fix for this issue?