Reference trouble

I want to pass a reference to a method in a separate public class. I have an actionEvent in my main class in a file main.java:
private void outlineActionPerformed(java.awt.event.ActionEvent evt) {                                       
        anotherclass.outline(Graphics2D g2);
    }I want this to reference a method in anotherclass.java:
static void outline(Graphics2D g2) {
    }The arguments are initialised in anotherclass like so:
public void paintComponent(Graphics g) {
  // Clear off-screen bitmap
  super.paintComponent(g);
  // Cast Graphics to Graphics2D
  Graphics2D g2 = (Graphics2D)g;
  g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING,
        RenderingHints.VALUE_ANTIALIAS_ON);
  }What gives?

I'm guessing you want to have a reference to the Graphics object used by the paintComponent method in the outlineActionPerformed method? Possibly so that you can do some painting in the actionPerformed method instead of the paintComponent method?
If so, that's probably a bad idea. A better way to do it would be to set some state data in the actionPerformed method, which the paintComponent method uses to paint the component. The paintComponent method could be using a new Graphics object each time it's called for all you know, so if you stored a reference to it, you could end up drawing on a Graphics that isn't being painted to the screen anymore.
If you want to call the outline method to delegate some painting, then call it from the paintComponent method, and pass it the Graphics that gets passed to paintComponent as a parameter. The outline method probably shouldn't be static either, but without seeing the rest of the design, I can't be sure.
private void outlineActionPerformed(java.awt.event.ActionEvent evt) {                                       
        someStuffToBeDrawn = whatever;
static void outline(Graphics2D g2) {
        // draw some stuff on g2 here maybe?
public void paintComponent(Graphics g) {
  // Clear off-screen bitmap
  super.paintComponent(g);
  // Cast Graphics to Graphics2D
  Graphics2D g2 = (Graphics2D)g;
  g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING,
        RenderingHints.VALUE_ANTIALIAS_ON);
   // do some painting based on someStuffToBeDrawn
   // maybe call outline(g2) so it can do some other painting?
  }

Similar Messages

  • EngineOnClose.txt

    I keep getting the following text file 'engineOnClose.txt' every time I quit my browser.  Does anybody know why?

    Followed txt messaging as per manual Reference chapter 9 and followed manual reference trouble shooting guide with negative results.  Tried hard reset which also yielded negative results.

  • Event data collection process unable to write data to the Data Warehouse

    Alert Description:
    Event data collection process unable to write data to the Data Warehouse. Failed to store data in the Data Warehouse. The operation will be retried.
    Exception 'InvalidOperationException': The given value of type Int32 from the data source cannot be converted to type tinyint of the specified target column.
    Running SCOM 2007 R2 on Server 2008 R2 with SQL Server 2008 R2. I can only find a single reference to this exact error on the Internet. It started occurring on a weekend. No changes were made to the SCOM server directly before this occurred. Anyone know
    what the error means and/or how to fix?

    Hello,
    I would suggest the following threas for your reference:
    Troubles with DataWarehouse database
    http://social.technet.microsoft.com/Forums/en-US/operationsmanagergeneral/thread/5e7005ae-d5d8-4b5c-a51c-740634e3da4e
    Data Warehouse configuration synchronization process failed
    to read state 
    http://social.technet.microsoft.com/Forums/en-US/systemcenter/thread/8ea1f4b9-115b-43cd-b66f-617533703047
    Thanks,
    Yog Li
    TechNet Community Support

  • G510 Virtualization "Not capable" after sleep

    I have a lenovo g510 with i7 4700mq processor and windows 8.1
    When i put my laptop to sleep (close lid or something) and start it, the virtualization goes from "Enabled" to "not capable".  Its in Task manager -> Performance.
    Most google searches say its due to buggy BIOS, any idea how i can report it to lenovo or any solutions to the problem.
    I use both VrtualBox and VMware Workstation, so i need virtualization enabled in the laptop, and don't want to restart my laptop everytime i need to use V Box.
    I'm on the latest bios for the laptop, 3.07.

    Hi Leo002,
    According to your description and considering you are working with VT-x, this issue may relate to VT-x .Here is a link for reference:
    Trouble-shooting Intel VT-x Issues
    https://communities.vmware.com/docs/DOC-8978
    NOTE: This response contains a reference to a third party World Wide Web site. Microsoft is providing this information as a convenience to you. Microsoft does not control these sites and has not tested any software
    or information found on these sites.
    As the link posted ,you may have to
    disable hibernate and/or sleep if the latest firmware does not resolve the issue.
    Best regards  

  • Trouble shooting apex application calling web-service reference

    Hi,
    I am developing an APEX application which calls a web-service reference. i am looking for ideas as to how to log necessary information for trouble shooting.
    i already thought about this -
    1. the response from the web-service is displayed to the user (via a collection object).
    but the issue is i want the administrator (who logs in at a later time) to see that an error occurred or what was the response from the web-service.
    Is there any in-built way of accessing this information (is it first of all stored somewhere automatically ?). the one possible solution i see is to create a table and log the info into this table along with user and session id.
    any ideas / pointers will greatly help me.
    Regards,
    Ramakrishnan

    It looks like you won't be able to test web service calls on apex.oracle.com. see this WebService on apex.oracle.com
    Edited by: tfa on Mar 18, 2013 9:59 AM

  • Trouble with Cross-References

    FM11 / DITA 1.2
    What could cause a particular cross reference to consistently NOT work? I know that's vague. I'll try to give a more specific example:
    Let's say I have a collection of xrefs across several XML files in a DITA map. Some xrefs might even point to the same item (usually a <title> tag with an ID attribute). On output to a book with FM components, particular xrefs just will not work (they output as "unresolved"). I can fix it manually in the FM file, but I'd rather it work correctly in the first place, especially since I deal with translation in to several languages, and if I can't get an xref to just work, I have to fix it many, many times.
    I've tried deleting the xref and starting again; I've tried changing the ID attribute in case there was some kind of conflict...I still have trouble with that particular xref (and this happens with more than one xref). What else can I try?
    Again, I know this is vague. I'd be happy to elaborate on relevant points. I just don't currently have time to write a massive description and I want to get this question out.
    Thanks in advance.

    Hi ohnehosen...
    Are you up to date on your FM11 patches? It's hard to say what could be causing this problem .. does sound strange.
    While this shouldn't be the problem, you might try linking your xref to the container "topic" element (topic, concept, task, whatever is the immediate parent of the title you're pointing at). While in theory you should be able to xref to a title, that's not really the intent, your cross-ref is referencing a "topic" not the title within the topic. The same goes for a figure or table, you reference the fig or table element not the title within those elements.
    I'd assume that the code in the FM-DITA plugin was designed to work by referencing the container ,it probably wasn't tested the way you're doing it, and there may be some flakiness that would cause this to not always work.
    Give it a try .. let us know how it goes.
    …scott

  • Trouble with anchor and reference attributes combined with a Correlation ID

    Greetings, I'm a little green on FIM and looking for some advice.
    We have an HR system where we store the information on Contractors, Interns, and Employees.
    The business process for converting Contractors and Interns to Employees is to terminate the Contractor and re-hire as an Employee. This gives us a different employee number for the "live" entry in the HR system.
    Also, there is a "Supervisor No" attribute that is a Reference attribute for their manager. This is their employee number.
    What do I do in FIM? If the Employee number is the anchor, won't the system consider the employee a new object? Is there a way to connect the new employee record to the metaverse object that was a contractor or intern, and update the anchor attribute (the
    new employee number)?
    I was thinking of using a different custom field in the HR system as the FIM_Sync. But just realized that if this became the anchor, then no managers would connect since the Supervisor No is an Employee number.
    Thanks in advance for helping.
    -Doug
    *** Update ***
    I read some of the articles on Correlation ID that are in the 2003 version of MIIS the TechNet library. So a follow up question would be what happens between the CS and MV when the HR object changes.. Assuming I have this FIM_Sync attribute to be my
    Correlation ID.
    Contractor is created. Employee ID is anchor and FIM_Sync field is populated.
    New object in CS
    Projected into MV
    Provisioned out to AD and other systems, but they don't have the FIM_Sync attribute in their schema.
    Business Event.. Contactor converted to Employee:
    Contractor in HR system terminated (employment_state) and FIM_Sync entry removed.
    Employee record created in HR system and FIM_Sync value populated with what it was in the contractor record
    New Employee object in CS
    Does Contractor get disconnected?
    Does the Employee CS object get joined to existing MV object?

    At one of my previous projects we solved the same scenario as following:
    1. That was not a fully automatic process.
    2. Once we receive event that Contractor is terminated in HR, we put that user in "Terminated Contractors" set, disabling his active accounts, where the object resides for 30 days (business policy) before his accounts are removed from target systems.
    3. There's a custom workflow which triggers a notification to administrators if the following criteria are met:
    Name/Surname of fresh Employee are equal to one of the members of "Terminated Contractors" set
    Employee record from HR came within a week after Contractor's termination date (also, a business policy, agreed at customer's level. HRs are lazy and not necessarily process that transfer same day).
    4. IAM Administrator contacts HR to ensure that persons in question are actually the same one. Upon confirmation, manual join is made. Once object is joined, Correlation ID is written back to HR (actually, a buffer database acting as HR source) to ensure
    that the join can be made automatically.
    We faced several problems, though, which are beyond the scope of FIM itself:
    1. HRs were creating Employee record before terminating Contractor's one. A major pain, since new accounts are created, et cetera.
    2. HRs were creating Employee records too late (that's why we set a "timeout" for a week, initially it was two days)
    3. We had a case once when Contractor was terminated and new Employee came with the same name, but those were different people and HR application doesnt allow to differentiate "contractor fired" and "contractor moves to employee" events. That's why we had
    to stick to a manual and documented procedure.

  • Trouble with references....

    I am trying to write and test a simple syncronized method that 'locks' a record in a database. The reason it is not working is because the instance of Record does not seem to be retaining the value I am setting/mutating. I have been struggling wiht the code for a few days now and I think I found the problem code.
    public synchronized long lock(int recNo) throws RecordNotFoundException {
         long lockCookie = -1;
         if(recNo >= 0 && recNo <= dbData.size()) {
              //get the record
              Record r = (Record)dbData.get(recNo);
              System.out.println("Extracted Instance Lock Cookie " + r.getLockCookie() + " Rec No " + r.getRecordNumber());
               If the record is locked then wait for it to unlock
              while (r.isLocked()) {
                   try {
                        System.out.println("Waiting");
                        wait();
                   } catch (InterruptedException ie) {}
              /* create a cookie based on the current time in milliseconds */
              lockCookie = new Date().getTime();
              /* set the lock cookie to the record*/
              r.setLockCookie(lockCookie);
              /* put the updated instance back into the ArrayList */
              dbData.set(recNo,r);
         } else {
              throw new RecordNotFoundException("Cannot Lock - Record Not Found");
         return lockCookie;
    }As you can see I create a 'lock cookie' and the call Record.setLockCookie(long). I assumed that this would change the reference that i get() from the ArrayList dbData. But if I try to lock that record again the SOP prints "Extracted Lock Cookie: -1" which is the default value when it should be the value I set. I added the line dbData.set(recNo,r) to ensure that the Object that has been modified was put back in the ArrayList. But the SOP still gives -1 as the value for the lockCookie. My app has a client that requests a lock, when it has a lock it can modify a record, but now if another client requests a lock on the same record it also recieves a lock becuase the isLocked() method is always returning false bacuase the records lockCookie after I extract it from the ArrayList is -1. I can't see anything wrong with my code so I'm hoping someone else can.

    As best as I can tell your question is the following.
    - You have a class of type 'Record'
    - Using an int index you set an instance into an array list.
    - You set an attribute of that instance.
    - When you retrieve it using the index the attribute is not set.
    Possible reasons.
    - You are not using the same ArrayList
    - When you retrieve it you are not retreiving it from the same source
    - Something is overwriting it.
    - The set method doesn't work.
    - The get method doesn't work.
    Depending on what you are doing it could also be because
    - You are running two different versions of the VM (and the data is not persisted and sync between.)
    - You are not persisting the data.

  • Trouble creating Web Service Reference

    I am using Apex 3.0 and trying to create a new web service reference from the Shared Components page.
    Clicking the 'Web Service Refernces' link however takes me back to the login screen ! The Url shown in the browser is as below
    http://localhost:7777/pls/apex30/f?p=4550:1:393172515481281::::FSP_AFTER_LOGIN_URL:\f?p=4000|170|1940120004338053||NO|||\
    Any idea why this may be happening ?

    Totally Weird !
    I cleaned out the contents of the FLOW_PAGE_CACHE table and all is fine now !

  • Trouble with wlappc -- unresolved library references

    I'm trying to pre-compile my Portal webapp projects JSPs using the wlappc Ant task. This is the relevent piece of my Ant script:
         <path id="wls.classpath">
              <path refid="java.classpath" />
              <dirset dir="${.java.src.output}" />
         </path>
         <property name="wls.classpath.prop" refid="wls.classpath"/>
         <echo level="debug">Classpath for wlappc (JSP compilation) is ${wls.classpath.prop}</echo>
         <wlappc deprecation="true" source="WebContent" forceGeneration="true" lineNumbers="true">
              <classpath refid="wls.classpath"/>
         </wlappc>
    And this is the error I am getting:
    [java] There are 1 nested errors:
    [java]
    [java] weblogic.utils.compiler.ToolFailureException: Error: Unresolved WebApp library references defined in weblogic.xml, of module 'C:\h\project\po
    rtal\projectportal\WebContent' [Extension-Name: wls-commonslogging-bridge-war, Specification-Version: 1, Implementation-Version: 1.0, exact-match: false]
    , [Extension-Name: wlp-groupspace-web-lib, Specification-Version: 9.2, Implementation-Version: 9.2.1, exact-match: false], [Extension-Name: wlp-tools-
    visitor-web-lib, Specification-Version: 9.2, Implementation-Version: 9.2.1, exact-match: false], [Extension-Name: wlp-collab-portlets-web-lib, Specifi
    cation-Version: 9.2, Implementation-Version: 9.2.1, exact-match: false], [Extension-Name: wlp-commonui-web-lib, Specification-Version: 9.2, Implementa
    tion-Version: 9.2.1, exact-match: false], [Extension-Name: wlp-services-web-lib, Specification-Version: 9.2, Implementation-Version: 9.2.1, exact-matc
    h: false], [Extension-Name: wlp-framework-full-web-lib, Specification-Version: 9.2, Implementation-Version: 9.2.1, exact-match: false], [Extension-Nam
    e: p13n-web-lib, Specification-Version: 9.2, Implementation-Version: 9.2.1, exact-match: false], [Extension-Name: beehive-controls-1.0-war, Specificat
    ion-Version: 1, Implementation-Version: 1.0, exact-match: false], [Extension-Name: jstl, Specification-Version: 1.1, Implementation-Version: 1.1.2, ex
    act-match: false], [Extension-Name: wlp-lookandfeel-web-lib, Specification-Version: 9.2, Implementation-Version: 9.2.1, exact-match: false], [Extensio
    n-Name: wlp-light-web-lib, Specification-Version: 9.2, Implementation-Version: 9.2.1, exact-match: false], [Extension-Name: wlp-wsrp-producer-web-lib,
    Specification-Version: 9.2, Implementation-Version: 9.2.1, exact-match: false], [Extension-Name: wlp-framework-common-web-lib, Specification-Version:
    9.2, Implementation-Version: 9.2.1, exact-match: false], [Extension-Name: wlp-framework-struts-1.2-web-lib, Specification-Version: 9.2, Implementatio
    n-Version: 9.2.1, exact-match: false], [Extension-Name: struts-1.2, Specification-Version: 1.2, Implementation-Version: 1.0, exact-match: false], [Ext
    ension-Name: beehive-netui-resources-1.0, Specification-Version: 1, Implementation-Version: 1.0, exact-match: false], [Extension-Name: beehive-netui-1
    .0, Specification-Version: 1, Implementation-Version: 1.0, exact-match: false], [Extension-Name: weblogic-controls-1.0-war, Specification-Version: 1,
    Implementation-Version: 1.0, exact-match: false]
    [java] at weblogic.servlet.utils.WebAppLibraryUtils.initWebAppLibraryManager(WebAppLibraryUtils.java:90)
    Thanks in advance for any help!

    hi...even i am facing the same problem...can you plsssssss tell me what have you done to resolve the issue...

  • Trouble with supposedly strictly-typed reference...

    I'm having some issues with supposedly strictly-typed references.
    Can anyone look at the code attached (LV2010) and tell me why the top example doesn't work and the bottom does. More over, what's the general way to make the top example work?
    The discussion of strict and weak typed is rather short in the documentation in the help. Any pointers to relevant documentation would be appreciated.
    Thanks!
    Solved!
    Go to Solution.
    Attachments:
    Test.zip ‏46 KB

    I swear I read that help page like ten times and now I finally see the caveat in documentation. It would be nice if they mentioned this in the Enum Property page or in the table for Strings[] in the documentation instead of hiding it in the documentation.
    That said, now that you say it, it's obvious why. I wish the error I received (1082, I believe) could also be a bit more specific as I don't explicitly make the enum a strict type def, it simply is implicitly.

  • Trouble with output to tape in PrPro 14 with AJA Kona.  Win7pro64. Output to HDCam (HDW-F500), prerolls and parks until reference is cycled. Won't do an audio only insert edit.

    I have downloaded and installed the latest drivers from AJA, but am still having trouble outputting to tape.

    Well, this is admittedly making my head spin, but would it be possible, with that level of frame rate mismatch, for recording to even take place? The deck was definitely set for 23.98 and PsF (that's what both the indicators said).
    At a point of boiling frustration, I performed an Assemble Edit (instead of the typical Insert, after I blacked a tape). When doing that - just for the heck of it - the recording went on for 83 minutes, it gave me a Lost Lock with 1 minute left in our end credits. I then rewound the tape for about 60 minutes and played. Got a Lost Lock in 20 seconds with a picture dropout.
    Since you're familiar with the deck, does this seem at all plausible? Does this feed your theory about a frame rate/communication mismatch?

  • How to convert from Finder Object reference to POSIX path

    I'm new to AppleScript. I'm super close to getting what I need done, but I've ran across a snag in the middle.
    The error I'm getting is Can’t make quoted form of POSIX path of item 1 of {«class docf» \"filename\" of «class cfol» \"foldername\" of «class cfol» \"Desktop\" of «class cfol» \"Username\" of «class cfol» \"Users\" of «class sdsk» of application \"Finder\"} into type Unicode text. the problem area is highlighted and notated below. I've looked all around online but can't find what I need.
    Thanks in advance for any and all help!
    set text item delimiters to "."
    tell application "Finder"
      set theFilestoChoose to every item of (choose file with prompt "Please select the file(s) you would like to move and rename" with multiple selections allowed) as list
      display dialog "Would you like to move these files to an existing folder and then rename them, or create a new folder and then rename them?" buttons {"Move to an existing folder and rename", "Create a new folder and rename"}
      if result = {button returned:"Move to an existing folder and rename"} then
      set firstnewname to "Aauuttoommaattoorr"
      repeat with index from 1 to the count of theFilestoChoose
      set theFilesChosenbeingrenamedfirsttime to item index of theFilestoChoose
      set filenamecount to text items of (get name of theFilesChosenbeingrenamedfirsttime)
      if number of filenamecount is 1 then
      set fileextension to ""
      else
      set fileextension to "." & item -1 of filenamecount
      end if
      set the name of theFilesChosenbeingrenamedfirsttime to firstnewname & index & fileextension as string
      end repeat
      log theFilesChosenbeingrenamedfirsttime
      set choosingtheplacetomove to choose folder with prompt "Select the folder to move to"
      set thechosenfoldersname to name of folder choosingtheplacetomove -- sets the folder name as text
      set AppleScript's text item delimiters to {"-"}
      set Numberofthemonthatthebeginningofthefoldername to text item 1 of thechosenfoldersname as string -- for later to append the number back on without having to ask again!
      set shortenedname to text item 2 of thechosenfoldersname as string
      set the name of choosingtheplacetomove to shortenedname as string
      set thefolderstemporarynameaslocation to choosingtheplacetomove as string
      move theFilestoChoose to folder thefolderstemporarynameaslocation
      log theFilestoChoose
      set allfilesindestinationfolder to every file in choosingtheplacetomove as alias list --
      set aInitials to the text returned of (display dialog "Whose camera were this/these pictures taken on?" default answer "")
      set filteredList to my filterList(allfilesindestinationfolder, aInitials) as list
      log filteredList
      -- everything above this is correct so far and works perfect
      --TROUBLE SECTION BELOW
      set theSortedfilterList to (sort filteredList by creation date) -- something happens here with the theSortedfilterList that makes it unintelligible to convert to POSIX later. but I need the files in the order that this line puts them.
      log theSortedfilterList
      set timetorenamelasttime to theSortedfilterList
      set newbasename to shortenedname
      repeat with index from 1 to the count of timetorenamelasttime
      set theonefile to item index of timetorenamelasttime
      set theonefilenamecount to text items of (get name of theonetwothreefile)
      if number of theonefilenamecount is 1 then
      set fileextensionone to ""
      else
      set fileextensionone to "." & item -1 of theonefilenamecount
      end if
      tell application "System Events" to set CreaDate to creation date of file theonefile
      set CreaDate2 to CreaDate as text -- need to trim down to the first 10 characters and eliminate the "-"
      set AppleScript's text item delimiters to {""}
      set shorteneddatename to text items 1 thru 10 of CreaDate2 as string
      set the name of theonefile to shorteneddatename & {"-"} & newbasename & {"-"} & aInitials & {"-"} & index & fileextensionone as string
      end repeat
      --Trouble section above
      set the name of choosingtheplacetomove to Numberofthemonthatthebeginningofthefoldername & "-" & shortenedname as string -- returns the month prefix to the foldername
      else if result = {button returned:"Create a new folder and rename"} then
      set repeatConfirmation to true --Boolean to decided if script should be repeated; default is to repeat
      repeat while (repeatConfirmation = true) --Repeat if Any Tests Are Failed
      set thefirstquestion to choose from list {"January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"} with title "Event Month Selection" with prompt "Select the month in which the event started. Select only one month:"
      set theMonthAnswer to result
      if theMonthAnswer = false then --"For historical reasons, choose from list is the only dialog command that returns a result (false) instead of signaling an error when the user presses the “Cancel” button."
      set repeatConfirmation to false
      set exitingeventmonth to display dialog ("You are exiting selecting the event month phase of the program. You will need to manually fix this decision") buttons {"OK"} with title "Exiting Event Month Selection"
      if button returned of exitingeventmonth = "OK" then
      set theMonthAnswer to ""
      end if
      else
      set confirmationanswer to display dialog "You selected " & theMonthAnswer & ", is this correct? " buttons {"Yes, that's correct.", "No, the picture(s) are from a different month."} with title "Confirm Event Month Selection"
      if button returned of confirmationanswer = "Yes, that's correct." then
      set repeatConfirmation to false
      else
      display dialog ("That's okay, you can select another again!") buttons {"OK"} with title "Return to Event Month Selection"
      end if
      end if
      end repeat
      log theMonthAnswer
      if theMonthAnswer = "" then
      set monthtonumber to "You have cancelled this action."
      log monthtonumber
      else if theMonthAnswer = {"January"} then
      set monthtonumber to "01"
      log monthtonumber
      else if theMonthAnswer = {"February"} then
      set monthtonumber to "02"
      log monthtonumber
      else if theMonthAnswer = {"March"} then
      set monthtonumber to "03"
      log monthtonumber
      else if theMonthAnswer = {"April"} then
      set monthtonumber to "04"
      log monthtonumber
      else if theMonthAnswer = {"May"} then
      set monthtonumber to "05"
      log monthtonumber
      else if theMonthAnswer = {"June"} then
      set monthtonumber to "06"
      log monthtonumber
      else if theMonthAnswer = {"July"} then
      set monthtonumber to "07"
      log monthtonumber
      else if theMonthAnswer = {"August"} then
      set monthtonumber to "08"
      log monthtonumber
      else if theMonthAnswer = {"September"} then
      set monthtonumber to "09"
      log monthtonumber
      else if theMonthAnswer = {"October"} then
      set monthtonumber to "10"
      log monthtonumber
      else if theMonthAnswer = {"November"} then
      set monthtonumber to "11"
      log monthtonumber
      else if theMonthAnswer = {"December"} then
      set monthtonumber to "12"
      log monthtonumber
      end if
      set theNameofFoldertoMake to text returned of (display dialog "Please enter the name of the new folder you are creating:" default answer "" with title "New Folder Name")
      set LocationOfNewFolder to choose folder with prompt "Choose the location of the new folder you are creating:"
      set theNewNameofFoldertoMake to monthtonumber & "-" & theNameofFoldertoMake
      set newfolderaction to make new folder at LocationOfNewFolder with properties {name:theNewNameofFoldertoMake}
      move theFilestoChoose to newfolderaction
      end if
    end tell
    --function
    on filterList(allfilesindestinationfolder, aInitials)
      set patterns to {aInitials as string, "Aauuttoommaattoorr"}
      set output to {}
      repeat with aFile in the allfilesindestinationfolder
      repeat with aPattern in patterns
      set filepath to aFile as string
      if filepath contains aPattern then
      set end of the output to aFile
      exit repeat
      end if
      end repeat
      end repeat
      return output
    end filterList

    Okay, so you wanted the debugging and error messages. Thank you for the coaching. Here is what I get from the following line:
    set theSortedfilterList to (sort filteredList by creation date)
    log theSortedfilterList
    Log returns:
    (*document file Aauuttoommaattoorr3.AVI of folder SnowDay of folder Desktop of folder Username of folder Users of startup disk, document file Aauuttoommaattoorr2.MOV of folder SnowDay of folder Desktop of folder Username of folder Users of startup disk, document file Aauuttoommaattoorr1.mov of folder SnowDay of folder Desktop of folder Username of folder Users of startup disk*)
    set pxFile to POSIX path of ((theSortedfilterList) as alias)
    Error: "Can’t make {«class docf» \"Aauuttoommaattoorr3.AVI\" of «class cfol» \"SnowDay\" of «class cfol» \"Desktop\" of «class cfol» \"Username\" of «class cfol» \"Users\" of «class sdsk» of application \"Finder\", «class docf» \"Aauuttoommaattoorr2.MOV\" of «class cfol» \"SnowDay\" of «class cfol» \"Desktop\" of «class cfol» \" Username \" of «class cfol» \"Users\" of «class sdsk» of application \"Finder\", «class docf» \"Aauuttoommaattoorr1.mov\" of «class cfol» \"SnowDay\" of «class cfol» \"Desktop\" of «class cfol» \" Username \" of «class cfol» \"Users\" of «class sdsk» of application \"Finder\"} into type alias." number -1700 from {«class docf» "Aauuttoommaattoorr3.AVI" of «class cfol» "SnowDay" of «class cfol» "Desktop" of «class cfol» "Username" of «class cfol» "Users" of «class sdsk», «class docf» "Aauuttoommaattoorr2.MOV" of «class cfol» "SnowDay" of «class cfol» "Desktop" of «class cfol» "Username" of «class cfol» "Users" of «class sdsk», «class docf» "Aauuttoommaattoorr1.mov" of «class cfol» "SnowDay" of «class cfol» "Desktop" of «class cfol» "Username" of «class cfol» "Users" of «class sdsk»} to alias
    That is why I labeled it with Finder Object reference won’t return POSIX path, because I tried what was suggested about using the POSIX path of line. I thought seeing the lines above and around it would help set the context.
    So I need those files, but I need them sorted by creation date so that they’re in that order for the next renaming step.

  • How do I reference the data object in a DataGrid to show an image correctly in Acrobat?

    I'm creating an inferface for an Acrobat application  and I'm having a issue with displaying an image in a grid.  When I hard code the source="statusNONE.png" it works as intended (with an image, not the image associated with each grid item), however, when I try to use the source="{data.@icon}" to reference the dataProvider (XMLListCollection) I get nothing.  Not a broken image or anything.  I think I may just not be referencing the XMLListCollection correctly, otherwise I don't know why it would work with hard coding vs. fetching the string from the XML.
    //Application Header (Flex 4.5)
    <?xml version="1.0" encoding="utf-8"?>
    <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
                                     xmlns:s="library://ns.adobe.com/flex/spark"
                                     xmlns:mx="library://ns.adobe.com/flex/mx"
                                     width="100%" height="100%" creationComplete="eaton_creationCompleteHandler(event)"
                                     currentState="Review">
    //Sample of XML that gets used as basis for XMLListCollection
    <Annots>
         <Annot name='TEST' index='14' feedback='' canConstruct='0' icon='statusNONE.png'/>
    </Annots>
    //creation of the XMLListCollection from String
    [Bindable] protected var fullXML:XML;
    [Bindable] protected var fullXMLCol:XMLListCollection;
    protected function loadXML(xmlString:String):void
          fullXML = new XML(xmlString);
         var fullXMLList:XMLList = fullXML.children();
          fullXMLCol = new XMLListCollection(fullXMLList);
    //DataGrid
    <s:DataGrid left="0" top="0" bottom="0" width="142" dataProvider="{fullXMLCol}"
                                            requestedRowCount="4" rowHeight="30"
                                            top.Confirm="87">
                        <s:columns>
                                  <s:ArrayList>
                                            <s:GridColumn dataField="@name" headerText="Annotations"></s:GridColumn>
                                            <s:GridColumn headerText="status" width="30" >
                                                      <s:itemRenderer>
                                                                <fx:Component>
                                                                          <s:GridItemRenderer>
                                                                                    <s:Image width="30" height="30" source="{data.@icon}"/> //THIS IS THE PART THAT SEEMS TO BE GIVNG ME TROUBLE!
                                                                          </s:GridItemRenderer>
                                                                </fx:Component>
                                                      </s:itemRenderer>
                                            </s:GridColumn>
                                  </s:ArrayList>
                        </s:columns>
                        <s:typicalItem>
                                  <fx:Object dataField1="Sample Data" dataField2="Sample Data" dataField3="Sample Data"></fx:Object>
                        </s:typicalItem>
              </s:DataGrid>
    Additional information.  I'm using the resources tab for the flash embedding in Acrobat for my images. This works when I am hard coding the file name string works for the source without having to add a full path, the images are not technically bundled into the swf.   I just don't understand why using the data object to get that same string would show different results.
    tl;dr: GridItemRenderer works to show images when hard coded but not when using {data}.
    UPDATE: Figured it out, needed to add a toString() to the data.@icon.   I had assumed it was a string being handed over, I assumed wrong.

    Probably because data.@icon isn't a String, it is an XMLList, and source property is an Object not a String so the runtime doesn't automatically convert it.
      Try [email protected]()

  • Cross references not picking up character styles in source text

    I'm getting some annoying odd behaviour with cross references in Frame 12.
    I have some tables, where the paragraph style in the cell is called "Cell Body" (nothing odd there).
    Quite a few of the cells only have one word in them, and that word is set to courier font with a character style (called "Code").
    Then, elsewhere in the document, I am referring to this text using cross references. I am referencing the paragraph style Cell Body, and the cross reference format applied is like this "<hyperlink><$paratext><Default ¶ Font>"
    "hyperlink" is another character style that makes the text go green.
    So, the cross reference out to take the text from the cell (in Courier) and reproduce it, coloured green.
    However for about half of these cross references, it isn't picking up the Code character style in the source text, so the cross ref is just green, no green courier.
    Things are further bamboozled when I output to HTML Help.
    In the CHM file, the cross refs which appear to work OK (green courier) are now just courier.
    The ones which failed to pick up the courier look the same as they do in Frame (just green).
    Any ideas as to what's going on?
    I've tried troubleshooting by clearing the cells, reapplying the para style and default character style, then reapplying the code character style, then replacing the cross reference - which sometimes seemed to fix it but didn't always.

    Arnis Gubins wrote:
    Using two character tags in-line together (a la <hyperlink><Code>) is asking for trouble. IIRC, FM doesn't re-apply these in order on an update and depending upon how they are defined (and what is set to AsIs), the outer one usually wins. .
    So why does the blimmin' dialog invite me to do precisely that, by providing me with a list of all the character styles I have, and allowing me to select as many of them as I like??? /sulks/   Indeed, if Frame still shipped with a printed user guide instead of  stupid "optimised for viewing on iPhones" online webhelp nonsense, I suspect I might very well be able to find an example in the manual of using multiple character styles in that dialog!  If it doesn't want you to use more than one, why doesn't it grey out after you add the first one? /sighs/  The concept is called "cascading styles", it's a fundamental web paradigm! And it works in the main body text - why not in Xrefs!
    Also, I have been very scrupulous to keep my character styles orthogonal so none of their AsIs's mash each other up.
    But, rant over, I shall follow your splendid suggestion for a "Code Hyperlink" style.
    Arnis Gubins wrote:
    Also, x-ref formatting may behave differently in the new Publishing modules depending upon ....
    ...Depending on how badly designed and buggy this new Frame12 feature is, I should say!   The Publish module should not randomly stop behaving in a WYSIWIG manner in completely undocumented fashion just because Adobe couldn't be bothered to code it properly.  /sighs/
    Frankly, for my current project, I've given up trying to jump through hoops for Publish - I'm concentrating on getting the Frame source right and assuming these quirks will be fixed in Frame 13 (or 14, depending on how superstitious they are). Because if I put in ad hoc workarounds for them in Frame 12, I (or a colleague) will only have to undo them later when they're fixed, and by then we'll all have forgotten what the original problem was.

Maybe you are looking for

  • HTML - how to open "Save as ..." for pdf link

    Here's the background of my problem. BACKGROUND:  I have a webpage for an eBook.  The eBook is a PDF.  The eBook can be downloaded by Mac and Window users.  I want Safari 6.0.5 for the Mac to open the "Save As ..." dialogue box when they click the PD

  • Wide black vertical band in display.

    My computer (MA590LL-late 2006) has just started displaying a 2.5" wide sold black vertical band just left of center. Otherwise it seems to be working just fine. I want to find out if this is an expensive repair before I take it to Apple because, giv

  • Biometric solution in apex oracle

    Hello Sir, I want to access bio metricc feature in Apex application . How can be use it and do any connectivity or through any procedure . hw can we attached biometric system to apex oracle application . Plz give me any solution . Thanx

  • Element 10 and Canon 5D Mark III RAW file

    My Element 10 can read my Canon 40D RAW files but not the 5D Mark III ones. I downloaded Element Camera RAW update 6.7 and updated Adobe App Manager but could not install the former. An error message indicates that this extension does not apply. Any

  • OPP Error Sorting on Function

    BI Publisher, Oracle Applications (EBS). In Microsoft Word (2003 SP3), I have Template Builder version 10.1.3.4, build 129. BI Publisher Server version, 5.6.3. I am trying to sort from within the template. Adding *<?sort:EMPLOYEE_NAME?>* does work. H