• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: ERXEC.newEditingContext() access
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ERXEC.newEditingContext() access


  • Subject: Re: ERXEC.newEditingContext() access
  • From: Paul Hoadley <email@hidden>
  • Date: Tue, 6 Jan 2009 17:50:52 +1030

On 02/01/2009, at 12:03 PM, Theodore Petrosky wrote:

ok... I am experimenting with the ajax examples and I added the UpdateDisplayGroup to my app (with alterations). I am populating the list with a db query:

categoryList = Category.fetchAllCategories(ERXEC.newEditingContext(), sortOrderings);

EOEditingContext ec = ERXEC.newEditingContext(); categoryList = Category.fetchAllCategories(ec, sortOrderings);

then:

dg = new WODisplayGroup();
dg.setObjectArray(categoryList);
dg.setNumberOfObjectsPerBatch(20);

I want to access the editingContext and save the changes from the save dialog. What I want is something like this in the save function:

dg.selectedObject().editingContext().saveChanges();

ec.saveChanges();

I am at a loss as to how to access the editingContext when I use ERXEC.newEditingContext().

Assigning it to a local variable will certainly give you access to the EC you're passing to fetchAllCategories() above. Does that solve your problem?



-- Paul.

w  http://logicsquad.net/
h  http://paul.hoadley.name/


_______________________________________________ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
References: 
 >ERXEC.newEditingContext() access (From: Theodore Petrosky <email@hidden>)

  • Prev by Date: Re: [WOCommunity] WO Marketplace Survey: last reminder
  • Next by Date: Re: Removing < > = etc. from the drop down in D2W search
  • Previous by thread: ERXEC.newEditingContext() access
  • Next by thread: Re: ERXEC.newEditingContext() access
  • Index(es):
    • Date
    • Thread