Removing "Run Only" attribute on AppleScript?

So, let's say I wrote a killer script. Now I want to use it as the base for another script, but i inadvertently saved my script as "run only".
Is there a way to change the attribute of this file (Sort of like a dos attrib command on a pc?)

You either misunderstand "Andreas's hope" or misrepresent it. It has nothing whatsoever to do with "open source", and whether or not you know how to crack into someone's deliberately hidden scripting does not in the remotest way affect your learning of AppleScript. It has to do with data protection. I am sure you are not in favour of making piracy easier.
I have spent many years encouraging people to learn AppleScript and helping them with their scripting. A decompiler could conceivably give information to someone with good scripting abilities, but what use it could possibly be to someone learning scripting is beyond me. If you are sincere in wishing to improve your scripting then I can assure you that if you found a suitable decompiler it would - unless you were very expert - only give you incomprehensible gobbledegook. A decompiler is most assuredly NOT a learning tool.
My apologies for upsetting you. Happy scripting!
 

Similar Messages

  • How to remove "Read Only" attribute on folders

    Hi
    I am logged in with my User account which has full control over my folders.<o:p></o:p>
    I have a folder that I tried to add modifications to, however i could not do so because the folder was classified as read only. I have full permissions to this folder. Previously the app that
    uses this folder could write to it quite happily, but today it fails. <o:p></o:p>
    The 'attributes' for the folder shows a solid square in the read-only box. If I 'un-box' the read-only and apply > ok, when I look at the attributes again the box is still checked.<o:p></o:p>
    So my question is, if it's not (which it shouldn't be) some sort of protected Windows folder, and I have full permissions on the folder (supposedly), why does Windows not respect my wishes,
    get out of the way, and let me set it to what I want it to be?<o:p></o:p>
    I have tried the following methods to fix this issue, but none of them work:<o:p></o:p>
    -Adjusting permissions and control, and changing security options<o:p></o:p>
    -Using a third party application such as "clear read only" to remove the check on the box<o:p></o:p>
    -Using the "attrib" function on the CMD prompt<o:p></o:p>
    -Boot Scan for virus/malware that is affecting folder attributes<o:p></o:p>
    -Running applications and CMD as administrator<o:p></o:p>
    I have heard that if using a NTFS harddrive, then all folders will be automatically “Read Only” and that it is impossible to change that attribute. I find this hard to believe, as all folders
    should have some way of being modified, regardless of what HDD I’m using. I obviously cannot change to FAT32, so how else can I get my folders to get rid of this ridiculous error!
    <o:p>I have also noticed that this problem is very common amongst Windows users. If this problem has been around for a while, how is it possible that no solution has presented itself.
    Regardless, we need a solution to it, because i can't do the things i need to while the Read Only attribute remains a constant on my folders. I thought it may be a virus, but my avast anti-virus did not pick up any infected areas when the scan was done. I
    have searched the internet, and no "fix" has solved this issue. The only fix i have not found is a reg edit that could completely remove this read only attribute from all folders. Though i feel this is not neccesary, as i only need the attribute
    to be removed from certain folders. Please kindly assist me with this issue, hopefully it will help many others too...</o:p>
    Many thanks.

    Have you taken ownership of the folder? Please first take ownership of the folder, then change the security options
    Take Ownership of a File or Folder
    http://technet.microsoft.com/en-us/library/cc753659.aspx
    If you have already did this, then run a scan with this tool,
    Malicious Software Removal Tool
    http://www.microsoft.com/en-in/download/malicious-software-removal-tool-details.aspx
    or copy this folder to another location, test again.
    Regards
    Yolanda
    TechNet Community Support

  • Applescript Editor saved as "Run only" - How do I open my work? Please help

    I just spent hours on an applescript project. I'm still new to the Applescript Editor, so when I saved it as a run-only application, I thought that it meant it was just exporting the app. I didn't realize that when I quit, it would not ask to save the file. So now I have a final application that I can't open. How can I get back to editing it?

    What I meant was that the indicator at the top center of the window probably should not have turned solid
    Wow, I've never noticed that before.
    Pretty cool..
    leading me to believe it was saved
    Well, it was saved but not as a file you could edit.
    It's like a file in a word processor. If you save it as plain text, it will remove all formatting and the icon at top would turn solid (indicating it is saved).
    But open it again and it won't have any formatting.
    But I don't mean to complain. I just wish I could open my work.
    I understand fully.
    Sometimes ya' gotta learn the hard way.
    On that note, a pet peeve of mine.
    You do make regular backups of your important files, yes? You at least haveTime Machine running?

  • Script to export a script as run-only via AppleScript Editor

    Hi,
    I have written a script that's creating a new script and than save it to the desktop as run-only.
    Now Apple has re-written the rules of AppleScript Editor so the run-only command had to go via 'Export' (and not 'Save' anymore).
    I can't figure out how to script it now... I even tried to script the menu's but that's only possible for all menu's without '...' ending it. For example: 'File > New' is scriptable, but 'File > Export...' is not.
    Script 1 is the script I want to get working, but if scripting the Export of AppleScript Editor is not possible, I want to get de workaround of Script 2
    Script 1:
    ==================================================
    set myScript to "
    set studentnumber to \"" & studentnumber & "\"
    set password to \"" & password & "\"
    tell application \"Safari\"
    tell application "AppleScript Editor"
    activate
    make new document with data myScript
              save document 1 as "application" in file ((path to desktop as Unicode text) & "Automatisch Inloggen op GLR.app") with run only
    -- save doesn't work anymore and has to be EXPORT...
              return
    close document 1
    end tell
    =================================================
    Script 2 (workaround, but doesn't work either)
    tell application "AppleScript Editor" to activate
    menu_click({"AppleScript Editor", "File", "Export..."})
    -- 'File > New' works but 'File > Export... not'
    on menu_click(mList)
              local appName, topMenu, r
    -- Validate our input
              if mList's length < 3 then error "Menu list is not long enough"
    -- Set these variables for clarity and brevity later on
              set {appName, topMenu} to (items 1 through 2 of mList)
              set r to (items 3 through (mList's length) of mList)
    -- This overly-long line calls the menu_recurse function with
    -- two arguments: r, and a reference to the top-level menu
              tell application "System Events" to my menu_click_recurse(r, ((process appName)'s ¬
                        (menu bar 1)'s (menu bar item topMenu)'s (menu topMenu)))
    end menu_click
    on menu_click_recurse(mList, parentObject)
              local f, r
    -- `f` = first item, `r` = rest of items
              set f to item 1 of mList
              if mList's length > 1 then set r to (items 2 through (mList's length) of mList)
    -- either actually click the menu item, or recurse again
              tell application "System Events"
                        if mList's length is 1 then
      click parentObject's menu item f
                        else
                                  my menu_click_recurse(r, (parentObject's (menu item f)'s (menu f)))
                        end if
              end tell
    end menu_click_recurse

    Applescript has changed a little. You can now save uncompiled scripts, but it would make no sense to save an uncompiled script as read-only, so trying to do that fails. Add a compile command before the save:
    tell application "AppleScript Editor"
      activate
              set doc to make new document with data myScript
      compile doc
              save doc as "application" in ((POSIX path of (path to desktop)) & "Automatisch Inloggen op GLR.app") with run only
              return
      close doc
    end tell

  • Applescript - save as "run only" gone missing

    Did OS X 10.7 do away with the ability to save Applescripts as run-only?  I just noticed that all my scripts compiled and saved previously as "run only" now have the Rosetta prohibitory symbol on them.
    Is there a work-around for saving Applescripts as run-only?  I prefer to open Applescript, run the compiled script in the background, then quit.

    On Mountain Lion I had the same problem. But it wasn't solved by choosing duplicate. When I chose application I only had the options, "Show start up screen" and "Stay open after run handler".
    The help menu suggested that "Run only" should be there but it is not.
    Anyone have any ideas?

  • How Can I View an AppleScript File that was Saved as "Run Only"?

    Hello. I would like to view the AppleScript of a file I downloaded. But when I show the package contents, find the script, and try to open it, I get a message saying that the file "main.scpt" could not be opened because it was saved as run-only. How can I view this file?

    Are you using the save version of Illustrator on both Mac and PC? If so, and you have the same fonts installed on both machines you should be able to open it without any problems. You may need to tell it which fonts to assign, they are not always named the same. If you don't need to edit the text, you could convert the text to outline and eliminate the need for fonts.

  • Applescript application(Run only)/Password protected

    Hi,
      I'm copying files from source to destination using input XL then relink the images in InDesign Files. Saved that Apple script as Application(Run Only).  When I run the application its throwing "0 doesn't understand the count message".  But Code is working fine for me. Don't know why. Can anyone help me...
    And also I need to protect that apple script using password as manual.  Is it possible??
    Thanks in Advance,
    Sudha K

    admin is the normal "admin rights" under SL.  I would NOT change these.  If you have an admin account then you have the proper rights.
    Regards

  • Edit a run only script

    Can I (And how in the world do I?) edit a script that someone has made as a run only file?

    Folder Actions needs to be enabled in order for you to use them. I think by default this is not. If you open AppleScript Utility App you can click the 'Set UP Actions…' button. From here you can manage which folders have what Action Scripts Attached to them. You can also do this via 'ctrl' clicking a folder. Folders with Action Scripts will just sit there until an adding item or removing item event is triggered the script then processes these items. There are also a set of sample scripts that should get you started… You can also put the default scripts into your finder menubar while your there…

  • Is there a way to have an iPad run only 1 app at a time?

    I am a tech support person and teachers are asking me if we can have a students iPad run only one app at a time. For instance, a group of students in biology would be allowed to run only the app for their biology book.
    Students have gotten so distracted during classtime with iMessage, web browsing, videos and games that it becomes virtually impossible to keep them on task in the classroom.
    I am aware of adding profiles to the devices, but this profile would only be for the biology class. It would then have to be removed or deactivated upon leaving the class.

    You can restrict iPads running iOS 6 to a single app via Guided Access:
    http://support.apple.com/kb/HT5509
    but that requires reconfiguration of the iPads whenever you want to set it up or deactivate or change it. There may be a mobile device management (MDM) system that would allow you to push out such changes "on the fly" but I can't say with certainty. Someone else here or in the iPad in the Enterprise forum may know.
    Otherwise it may be necessary to implement an administrative solution such as banning use of iPads in class or enforcing consequences should a student be using the iPad for inappropriate functions.
    Regards.

  • HELP- "IPOD Cant Be Synced.  The Disk is locked"  Cant remove Read only

    I cannot remove read only from the IPod Control folder. It won't let me. I cant load music to my ipod, which I previously have with same computer, itunes, everything. I have the most updated itunes, software, etc.
    Can anyone help me? I have no clue what to do. I tried to right click on the ipod disk and run an error check. that didnt work. I'm clueless. Help!

    Hello Mark,
    And welcome to Apple Discussions!
    I don't really have any suggestions for you, but I can point you to an older thread where you might find help. Check out this old post from another forum member who managed to address this issue him/herself.
    http://discussions.apple.com/thread.jspa?threadID=1651418
    B-rock

  • Remove an html attribute in a html document

    Hi...
    Can someone give me a piece of code describing how I can remove a html attribute for the text under the current caret position or selection?
    If I have a <font class="..."> tag, I want to delete the class attribute, but maybe still want to have the font tag because it can contain some other attributes, face, size etc.
    I can get the current attribute with the AttributeSet attr = getCharacterElement().getAttributes().
    To be able to delete an attribute in the AttributeSet, I have to put it in a SimpleAttributeSet object?
    If I do that and delete the class attribute with the removeAttribute method and then put the changed AttributeSet back with setCharacterAttributes and setting the replace parameter to true, the selected text is removed...
    Any solutions?

    I don't know exact answer. It's only my suggestions!
    Foreground color in HTMLDocument differ from DefaultStyledDocument
    in the HTMLDocument color is specified with appropriate TAGs (like <FONT>).
    when you change source html text the document tree structure is changed according to html content and your settings are disappeared.
    Try to change source html text.
    Could you tell me what do you want to achieve?
    may be i can suggest a solution...
    i tryed to create an example... but it's unstable.
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    import javax.swing.text.*;
    import javax.swing.text.html.*;
    import javax.swing.event.*;
    import javax.swing.tree.*;
    import java.util.*;
    class Test extends JFrame {
    JEditorPane edit;
    public Test(){
    super("Test");
    this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    getContentPane().setLayout(new BorderLayout());
    edit = new JEditorPane();
    edit.setEditorKit(new HTMLEditorKit());
    //edit.setDocument(new MyHTMLDocument());
    edit.setEditable(true);
    edit.setText("<HTML><FONT CLASS='c1' COLOR=RED><B>red text</B></FONT></HTML>");
    JScrollPane scroll=new JScrollPane(edit);
    getContentPane().add(scroll,BorderLayout.CENTER);
    JTree tree=new JTree((TreeNode)edit.getDocument().getDefaultRootElement());
    getContentPane().add(tree,BorderLayout.WEST);
    JButton btn=new JButton("test");
    ActionListener lst=new ActionListener() {
    public void actionPerformed(ActionEvent e){
    HTMLDocument html_doc=(HTMLDocument)edit.getDocument();
    Element el=html_doc.getCharacterElement(1);
    MutableAttributeSet newAttr=new SimpleAttributeSet();
    StyleConstants.setForeground(newAttr,Color.blue);
    html_doc.setCharacterAttributes(1,3,newAttr,false);
    try {
    html_doc.insertString(0,"",null); //this call do nothing but notifies that document is changed
    catch (Exception ex) {
    ex.printStackTrace();
    Element font=el.getParentElement();
    MutableAttributeSet attr=(MutableAttributeSet)el.getAttributes();
    btn.addActionListener(lst);
    getContentPane().add(btn,BorderLayout.SOUTH);
    setSize(300,300);
    setVisible(true);
    public static void main(String a[]) {
    new Test();
    and don't worry about dukes:-))
    i just want to help you.
    best regards
    Stas

  • Removal of Compound attributes of an info object in the BEx display

    Hi,
    i have a Info object Parentid which is compounded with the Parent Source and a Date.
    I have to remove the compounded attributes when I am displaying the info object Parentid in the BEx report.
    What is the best way of doing this?
    Any help is deeply appreciated
    Regards

    Hi Arvind,
    put the compounding attributes into the filter section and make sure the ouput is restricted to only one compounding value.
    regards
    Siggi

  • Dbms_scheduler - dbms_aq - dbms_aqadm - event driven job runs only once/sec

    hi, i tried here to process events with 2 jobs... surprisingly i had to call dbms_lock.sleep(1) to be able to enqueue events
    at inserts in a row ... even more surprisingly the enqueuing doesn't function if the processing (prc_evsched) lasts some seconds...
    how must the code be changed to be able to enqueue all events after the inserts without any sleep()?
    and how must the code be changed to be able to enqueue all events with a proc (prc_evsched) running longer?
    thanx in advance for your help!
    --evsched
    h4.
    --to remove all test-objects
    h4.
    --test table
    h4.
    --define the object type to act as the payload for the queue
    h4.
    --creating the event queue
    h4.
    --creating the proc for the prog/job
    h4.
    --creating the proc for the prog/job
    h4.
    --creating the program
    h4.
    --creating the first job (for parallel execution)
    h4.
    --creating the second job (for parallel execution)
    h4.
    --test block
    h4.
    --test scenarios/results
    h4.
    --to remove all test-objects
    DECLARE
    exc_ora_27475 EXCEPTION; --ora-27475: <job_name> muss job sein
    PRAGMA EXCEPTION_INIT (exc_ora_27475, -27475);
    exc_ora_27476 EXCEPTION; --ora-27476: <program_name> ist nicht vorhanden
    PRAGMA EXCEPTION_INIT (exc_ora_27476, -27476);
    exc_ora_24010 EXCEPTION; --ORA-24010: QUEUE SYSGIS.EVENT_QUEUE ist nicht vorhanden
    PRAGMA EXCEPTION_INIT (exc_ora_24010, -24010);
    exc_ora_24002 EXCEPTION; --ORA-24002: QUEUE_TABLE SYSGIS.EVENT_QUEUE_TAB ist nicht vorhanden
    PRAGMA EXCEPTION_INIT (exc_ora_24002, -24002);
    exc_ora_4043 EXCEPTION; --ORA-04043: Objekt T_EVENT_QUEUE_PAYLOAD ist nicht vorhanden
    PRAGMA EXCEPTION_INIT (exc_ora_4043, -4043);
    exc_ora_942 EXCEPTION; --ORA-00942: Tabelle oder View nicht vorhanden
    PRAGMA EXCEPTION_INIT (exc_ora_942, -942);
    exc_ora_2289 EXCEPTION; --ORA-02289: Sequence ist nicht vorhanden.
    PRAGMA EXCEPTION_INIT (exc_ora_2289, -2289);
    v_fpos PLS_INTEGER := 1;
    BEGIN
    v_fpos := 10;
    BEGIN
    --remove job
    SYS.DBMS_SCHEDULER.DROP_JOB(job_name=> 'job_evsched', FORCE=>TRUE);
    EXCEPTION WHEN exc_ora_27475 THEN NULL;
    END;
    v_fpos := 12;
    BEGIN
    --remove job
    SYS.DBMS_SCHEDULER.DROP_JOB(job_name=> 'job_evsched_2', FORCE=>TRUE);
    EXCEPTION WHEN exc_ora_27475 THEN NULL;
    END;
    v_fpos := 20;
    BEGIN
    --remove program
    SYS.DBMS_SCHEDULER.DROP_PROGRAM(program_name=>'prg_evsched',FORCE=>TRUE);
    EXCEPTION WHEN exc_ora_27476 THEN NULL;
    END;
    v_fpos := 30;
    BEGIN
    -- stop the event queue.
    DBMS_AQADM.stop_queue (queue_name => 'evsched_event_queue');
    EXCEPTION WHEN exc_ora_24010 THEN NULL;
    END;
    v_fpos := 40;
    BEGIN
    -- drop the event queue.
    DBMS_AQADM.drop_queue (queue_name => 'evsched_event_queue');
    EXCEPTION WHEN exc_ora_24010 THEN NULL;
    END;
    v_fpos := 50;
    BEGIN
    -- Remove the queue table.
    DBMS_AQADM.drop_queue_table(queue_table => 'tab_evsched_event_queue');
    EXCEPTION WHEN exc_ora_24002 THEN NULL;
    END;
    v_fpos := 60;
    BEGIN
    -- remove type
    EXECUTE IMMEDIATE 'DROP TYPE typ_evsched_payload';
    EXCEPTION WHEN exc_ora_4043 THEN NULL;
    END;
    v_fpos := 70;
    BEGIN
    -- remove table
    EXECUTE IMMEDIATE 'DROP TABLE tab_evsched';
    EXCEPTION WHEN exc_ora_942 THEN NULL;
    END;
    v_fpos := 80;
    BEGIN
    -- remove sequence
    EXECUTE IMMEDIATE 'DROP SEQUENCE seq_evsched';
    EXCEPTION WHEN exc_ora_2289 THEN NULL;
    END;
    EXCEPTION
    WHEN OTHERS THEN
    dbms_output.put_line('v_fpos='||v_fpos);
    END;
    h4.
    --test table
    CREATE TABLE tab_evsched
    ( id NUMBER
    , sys_date DATE
    , status VARCHAR2(1)
    , processed VARCHAR2(1) DEFAULT 'N'
    , processed_by varchar2(128)
    GRANT DELETE, INSERT, SELECT, UPDATE ON tab_evsched TO PUBLIC
    CREATE SEQUENCE seq_evsched
    h4.
    --define the object type to act as the payload for the queue
    CREATE OR REPLACE TYPE typ_evsched_payload AS OBJECT
    ( event_name VARCHAR2(30)
    , tab_evsched_id NUMBER
    , daterf DATE
    h4.
    --creating the event queue
    BEGIN
    -- Create a queue table to hold the event queue.
    DBMS_AQADM.create_queue_table
    ( queue_table => 'tab_evsched_event_queue'
    , queue_payload_type => 'typ_evsched_payload'
    , multiple_consumers => TRUE
    , COMMENT => 'Queue Table For Event Messages'
    -- Create the event queue.
    DBMS_AQADM.create_queue
    ( queue_name => 'evsched_event_queue'
    , queue_table => 'tab_evsched_event_queue'
    , queue_type => DBMS_AQADM.NORMAL_QUEUE
    , max_retries => 0
    , retry_delay => 0
    , dependency_tracking => FALSE
    , comment => 'Test Object Type Queue'
    , auto_commit => FALSE
    -- Start the event queue.
    DBMS_AQADM.start_queue
    ( queue_name => 'evsched_event_queue'
    END;
    h4.
    --creating the proc for the prog/job
    CREATE OR REPLACE PROCEDURE prc_evsched
    ( p_message IN typ_evsched_payload
    , p_job_name IN VARCHAR2
    IS
    BEGIN
    UPDATE tab_evsched
    SET processed = 'J'
    , processed_by = p_job_name
    , sys_date = p_message.daterf
    WHERE 1=1
    AND id = p_message.tab_evsched_id
    dbms_lock.sleep(5); --#sleep-1#
    COMMIT;
    END prc_evsched;
    h4.
    --creating the program
    DECLARE
    exc_ora_27476 EXCEPTION; --ora-27476: <program_name> ist nicht vorhanden
    PRAGMA EXCEPTION_INIT (exc_ora_27476, -27476);
    BEGIN
    BEGIN
    SYS.DBMS_SCHEDULER.DROP_PROGRAM(program_name=>'prg_evsched',FORCE=>TRUE);
    EXCEPTION
    WHEN exc_ora_27476 THEN
    NULL;
    END;
    SYS.DBMS_SCHEDULER.CREATE_PROGRAM
    ( program_name => 'prg_evsched'
    , program_type => 'STORED_PROCEDURE'
    , program_action => '"SYSGIS"."PRC_EVSCHED"'
    , number_of_arguments => 2
    , enabled => FALSE
    , comments => 'Program-Komponent für den Test von DBMS_SCHEDULER'
    --event message as the first param to prc_evsched 
    DBMS_SCHEDULER.DEFINE_METADATA_ARGUMENT
    ( program_name => 'prg_evsched'
    , argument_position => 1
    , metadata_attribute => 'EVENT_MESSAGE'
    --name of the job as the second param to prc_evsched 
    SYS.DBMS_SCHEDULER.define_program_argument
    ( program_name => 'prg_evsched'
    , argument_name => 'p_job_name'
    , argument_position => 2
    , argument_type => 'VARCHAR2'
    , default_value => 'dummy'
    --enable program   
    SYS.DBMS_SCHEDULER.ENABLE(NAME=>'prg_evsched');
    END;
    h4.
    --creating the first job (for parallel execution)
    DECLARE
    exc_ora_27475 EXCEPTION; --ora-27475: <job_name> muss job sein
    PRAGMA EXCEPTION_INIT (exc_ora_27475, -27475);
    BEGIN
    BEGIN
    --remove job
    SYS.DBMS_SCHEDULER.DROP_JOB(job_name=> 'job_evsched', FORCE=>TRUE);
    EXCEPTION WHEN exc_ora_27475 THEN NULL;
    END;
    DBMS_SCHEDULER.create_job
    ( job_name => 'job_evsched'
    , program_name => 'prg_evsched'
    , start_date => SYSTIMESTAMP
    , event_condition => 'tab.user_data.event_name = ''MYEVENT'''
    , queue_spec => 'evsched_event_queue'
    , auto_drop => FALSE
    , enabled => FALSE
    SYS.DBMS_SCHEDULER.SET_JOB_ARGUMENT_VALUE
    ( job_name => 'job_evsched'
    , argument_name => 'p_job_name'
    , argument_value => 'job_evsched'
    SYS.DBMS_SCHEDULER.ENABLE(NAME=>'job_evsched');
    END;
    h4.
    --creating the second job (for parallel execution)
    DECLARE
    exc_ora_27475 EXCEPTION; --ora-27475: <job_name> muss job sein
    PRAGMA EXCEPTION_INIT (exc_ora_27475, -27475);
    BEGIN
    BEGIN
    --remove job
    SYS.DBMS_SCHEDULER.DROP_JOB(job_name=> 'job_evsched_2', FORCE=>TRUE);
    EXCEPTION WHEN exc_ora_27475 THEN NULL;
    END;
    DBMS_SCHEDULER.create_job
    ( job_name => 'job_evsched_2'
    , program_name => 'prg_evsched'
    , start_date => SYSTIMESTAMP
    , event_condition => 'tab.user_data.event_name = ''MYEVENT'''
    , queue_spec => 'evsched_event_queue'
    , auto_drop => FALSE
    , enabled => FALSE
    SYS.DBMS_SCHEDULER.SET_JOB_ARGUMENT_VALUE
    ( job_name => 'job_evsched_2'
    , argument_name => 'p_job_name'
    , argument_value => 'job_evsched_2'
    SYS.DBMS_SCHEDULER.ENABLE(NAME=>'job_evsched_2');
    END;
    h4.
    --test block
    DECLARE
    PROCEDURE pr_ins_tab_evsched
    ( p_id IN NUMBER
    , p_status IN VARCHAR2
    IS
    BEGIN
    INSERT INTO tab_evsched(id,status) VALUES (p_id, p_status);
    COMMIT;
    --enqueue the MYEVENT-event
    IF p_status = 'M' THEN
    --enqueue works in 1sekunden-taktung.... !?
    dbms_lock.sleep(1); --#sleep-2#
    DECLARE
    v_enqueue_options DBMS_AQ.enqueue_options_t;
    v_message_properties DBMS_AQ.message_properties_t;
    v_message_handle RAW(16);
    v_queue_msg typ_evsched_payload;
    BEGIN
    v_queue_msg := typ_evsched_payload
    ( event_name => 'MYEVENT'
    , tab_evsched_id => p_id
    , daterf => SYSDATE
    v_enqueue_options.VISIBILITY := DBMS_AQ.ON_COMMIT;
    v_enqueue_options.delivery_mode := DBMS_AQ.PERSISTENT;
    v_message_properties.PRIORITY := 1;
    v_message_properties.DELAY := DBMS_AQ.NO_DELAY;
    v_message_properties.EXPIRATION := DBMS_AQ.NEVER;
    v_message_properties.CORRELATION := 'TEST MESSAGE';
    DBMS_AQ.enqueue
    ( queue_name => 'evsched_event_queue'
    , enqueue_options => v_enqueue_options
    , message_properties => v_message_properties
    , payload => v_queue_msg
    , msgid => v_message_handle
    END;
    END IF;
    COMMIT;
    END pr_ins_tab_evsched;
    BEGIN
    DELETE tab_evsched;
    pr_ins_tab_evsched (seq_evsched.NEXTVAL,'M');
    pr_ins_tab_evsched (seq_evsched.NEXTVAL,'M');
    pr_ins_tab_evsched (seq_evsched.NEXTVAL,'M');
    pr_ins_tab_evsched (seq_evsched.NEXTVAL,'M');
    pr_ins_tab_evsched (seq_evsched.NEXTVAL,'M');
    pr_ins_tab_evsched (seq_evsched.NEXTVAL,'M');
    pr_ins_tab_evsched (seq_evsched.NEXTVAL,'M');
    pr_ins_tab_evsched (seq_evsched.NEXTVAL,'M');
    END;
    SELECT * FROM tab_evsched ORDER BY id;
    SELECT * FROM sysgis.tab_evsched_event_queue;
    h4.
    --test scenarios/resultsh
    h5.
    --test results #sleep-1#=5, #sleep-2#=0
    --job (job_evsched) runs only once, only the first event is enqued/processed
    ID SYS_DATE STATUS PROCESSED PROCESSED_BY
    9 22.03.2012 17:00:41 M J job_evsched
    10 (Null) M N (Null)
    11 (Null) M N (Null)
    12 (Null) M N (Null)
    13 (Null) M N (Null)
    14 (Null) M N (Null)
    15 (Null) M N (Null)
    16 (Null) M N (Null)
    h5.
    --test results #sleep-1#=0, #sleep-2#=1
    --jobs (job_evsched/job_evsched2) run alternately, every events are enqued/processed
    ID SYS_DATE STATUS PROCESSED PROCESSED_BY
    25 22.03.2012 17:04:31 M J job_evsched_2
    26 22.03.2012 17:04:32 M J job_evsched_2
    27 22.03.2012 17:04:33 M J job_evsched
    28 22.03.2012 17:04:34 M J job_evsched_2
    29 22.03.2012 17:04:35 M J job_evsched_2
    30 22.03.2012 17:04:36 M J job_evsched_2
    31 22.03.2012 17:04:37 M J job_evsched
    32 22.03.2012 17:04:38 M J job_evsched_2
    h5.
    --test results #sleep-1#=5, #sleep-2#=1
    --jobs (job_evsched/job_evsched2) run alternately, only two events are enqued/processed
    ID SYS_DATE STATUS PROCESSED PROCESSED_BY
    41 22.03.2012 17:07:42 M J job_evsched_2
    42 (Null) M N (Null)
    43 (Null) M N (Null)
    44 (Null) M N (Null)
    45 (Null) M N (Null)
    46 (Null) M N (Null)
    47 22.03.2012 17:07:48 M J job_evsched
    48 (Null) M N (Null)
    */

    hi, thank you for your (fast) answer! that is the solution to my problem!
    now i have a follow-up question:
    i've got a procedure, that runs between 1 and 2 minutes long. unlimited running lightweight jobs
    would freeze the db...
    how can the count of the parallel running lightweight-jobs be limited?
    according to the documentation it is not possible:
    There is no explicit limit to the number of lightweight jobs that can run simultaneously to process multiple instances of the event.
    However, limitations may be imposed by available system resources.
    could you explain to me, what it (...available system recources...) means?
    eventually what i would like to have: max. two parallel running (lightweight) jobs....
    thank you in advance, bye, á
    ps: can i attach a file to the post anyway?
    Edited by: user4786904 on 23.03.2012 07:22

  • Lifecycle issue with table binding + read-only attributes: ADF BUG

    Hello all,
    I have found what I believe to be an easily reproducible bug in ADF that reproduces in 10.1.3.x, but not in 11g (at least not in drop 6). The best way to describe the bug would be to walk through a simple set of steps to reproduce the bug:
    1). Create a new application (ADF BC + ADF Faces).
    2). In the model project, create a new Entity Object from the Employee table in the default HR schema. Allow JDev to create an updatable view object and an AM as well.
    3). Put a validation rule on the first name attribute of the EO (can be anything, really - I made mine so that the first name cannot be "foo").
    4). Test everything using the BC tester if you like.
    5). In the UI project, create a new JSPX page.
    6). Drag the updatable VO on to your page as an updatable af:table.
    7). Put an af:commandButton on the page. Bind its Action or ActionListener to a method in a new backing bean. Put some simple code (I used System.out.println) in the backing bean method.
    8). Run the jspx page.
    9). Put some invalid data in (e.g. "foo" in the first name field) and click the af:commandButton. Verify that you get an error message and that the Action/ActionListener method DOES NOT fire. So far, so good.
    10). Now, to demonstrate the problem. First, look at the page definition for the jspx file. Identify the first attribute that is mentioned (in my case, it was the employee id).
    11). Go to the updatable view object and make the attribute from #10 read-only or updatable when new only.
    12. Now, repeat step 9 - you should see the error message AND also see that the Action/ActionListener method was executed. You will also see in the messages window that ADF attempted to set the value of the read-only attribute, and thus got a ReadOnlyAttrException.
    This issue only happens if the first attribute mentioned in the table binding is read-only. A workaround would simply be to re-order the attributes in the table binding of the pagedef so that the first attribute isn't read-only.
    Don't ask how I figured this out ;)
    Best,
    John

    Hi Frank,
    Yes, I simply scripted it out this way to contrast the behaviour if the first attribute was read-only vs not read-only. I found the issue on a page in our app that was simply drag-and-drop the VO from the data control on the page.
    It's quite annoying, because our particular use case that hit this error is a "save" button on the page. If the commit operation doesn't return any errors (and it doesn't in this use case!), we add a JSF message saying "save successful" - then the attribute errors are further added later in the page lifecycle, so we get 3 messages: "Save successful" and "Fix this error" and "Tried to set read-only attribute" - quite confusing to the end-user when the only message they should see is "fix this error."
    At any rate, the fix is to simply re-order the attributes in the page definition - that doesn't affect the UI at all, other than to fix this issue.
    John

  • Updating Media Content - stuck at Reset Read Only Attributes.

    I'm currently using - MDT 2010 on Windows 7 on a Virutal Machine. I deploy my images using a USB stick. (Advanced Configuration / Media). The process of creating a selection profile, Creating Media, and updating my media works perfectly.
    I wanted to move to MDT 2012 SP1 on Server 2008 R2 platform. So I installed AIK, MDT 2012 SP1, etc on a Server 2008 R2 Virtual Machine. I setup the MDT same way as my current working model and it was looking good. Next I created my Selection Profile
    and Media. Then when I ran "Update Media" it seems to work until it gets stuck at the last process "Reset Read Only Attributes"
    Looking for any advice on why it might keep getting stuck here. The only way I can exit the process it to "Stop Execution"
    Reminder - on my Win 7 / MDT 2010 box, it works fine and this process completes.
    Thanks for any feedback.

    What is happening here is that MDT Litetouch console is calling OSCDIMG.exe, and that program has stopped.
    Sadly, MDT does not capture the OSCDIMG.exe output for analysis, so we are stuck here.
    I have personally encountered problems with OSCDIMG.exe running on my Windows 8 box, where images created with source files from the C: pass, however when the source files are placed on a "Storage Spaces" volume, the program hangs. No response from MSFT.
    If you need help diagnosing the problem, you can run OSCDIMG from a console window, just to see what the output is
    OSCDIMG.exe -u2 -udfver102 -m -o -h -w4 "<MediaSrc>" %temp%\Dest.iso
    Longer:
    OSCDIMG.exe -u2 -udfver102 -m -o -h -w4 -yo"<Path_to_Bootorder.txt>" -bootdata:2#p0,e,b"<Path_TO_ETFSBoot.com>" #pEF,e,b"<Path_TO_EFIsys.bin>" "<MediaSrc>" %temp%\Dest.iso
    -k
    Keith Garner - Principal Consultant [owner] -
    http://DeploymentLive.com

Maybe you are looking for

  • Attribute values from VO are being shuffled

    Hi , I have a VO which has a UNION query in it..The query is fetching the proper details however when we are putting it in VO and trying to get the values of attributes mentioned in it, its giving shuffled values for example the Value of column A is

  • Autonomous 1231/1242 Radius Config Help. What is this not working?

    Hey Guys, I can't seem to get the SSID RadiusTest to work properly. Windows PC's show "Windows was unable to find a certificate to log you into the network". Macs don't authenticate either. Radius server isn't seeing any requests at all. Radius serve

  • Export to excel problems in visual composer?Help!!!

    hello all,           these days my four table were integrated in one iview,and ues the same variant to control the four queries,and did anyone could help me to accomplish the function of the four table,and can we diplay a window to display a key figu

  • Regarding the query containing $[$28.1.0]

    Hi, Can someone help me with this code.. SELECT (T0.OnHand-T0.IsCommited) FROM OITW T0 WHERE T0.ItemCode = $[$5.1.0] and  T0.WhsCode = $[$28.1.0] I have a document downloaded from SAP site. This query works fine when i hard code the value in place of

  • Constant rebooting iphone 4s, responding slow, battery indication

    My iphone 4s is contantly rebooting when attached on power outlet or mac , when not it is responsing slow on the screen when you want to do anything. Also the % of the battery stays in the same number and does not change. Is there a solution for this