Re: New Eclipse Project not seeing Model

From: Chuck Hill (chil..lobal-village.net)
Date: Thu Jun 07 2007 - 13:23:23 EDT

  • Next message: Mike Schrag: "Re: Build server is unreachable"

    Moving to WOLips list...

    A couple of basic things to check:
    1. Are you running this as a WO Application and not a Java Application?

    2. What is the working directory set to in the launch config?

    3. Are you setting the model's connection dictionary programmatically?

    And what do you mean by "I suspect that it had to do with the name of
    the model file not being the default name."?

    Chuck

    On Jun 7, 2007, at 4:37 AM, Calven Eggert wrote:

    > The model appears in the builds Resource folder. Hmmm, is there
    > something else I should be checking for?
    >
    >
    > On 6/6/07 11:15 AM, "David Holt" <programmingos..ac.com> wrote:
    >
    >> If you add your own model, you will likely need to add it to your
    >> Resources subfolder for it to be built properly. If you put it at
    >> root level, your default settings likely won't pick it up.
    >>
    >> David
    >>
    >> On 6-Jun-07, at 6:58 AM, Calven Eggert wrote:
    >>
    >>> Good Morning all,
    >>>
    >>> I’ve created a new Eclipse/WOLips application project,
    >>> eSignature, and I’ve added a model file called eSignatureModel.
    >>> When running the application and add a new record into my
    >>> database I get the following message:
    >>>
    >>> ...
    >>> com.webobjects.eoaccess.EOObjectNotAvailableException:
    >>> databaseContextForModelNamed: cannot find model named eSignature
    >>> associated with this EOEditingContext at
    >>> com.webobjects.eoaccess.EOUtilities.databaseContextForModelNamed
    >>> (EOUtilities.java:769) at
    >>> com.webobjects.eoaccess.EOUtilities.rawRowsForSQL
    >>> (EOUtilities.java:547) at
    >>> Application.databaseContextNewPrimaryKey(Application.java:97)
    >>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    >>> at sun.reflect.NativeMethodAccessorImpl.invoke
    >>> (NativeMethodAccessorImpl.java:39) at
    >>> sun.reflect.DelegatingMethodAccessorImpl.invoke
    >>> (DelegatingMethodAccessorImpl.java:25) at
    >>> java.lang.reflect.Method.invoke(Method.java:324) at
    >>> com.webobjects.foundation.NSSelector._safeInvokeMethod
    >>> (NSSelector.java:120) at
    >>> com.webobjects.foundation._NSDelegate._perform(_NSDelegate.java:
    >>> 225) at com.webobjects.foundation._NSDelegate.perform
    >>> (_NSDelegate.java:170) at
    >>> com.webobjects.eoaccess.EODatabaseContext._primaryKeyForObject
    >>> (EODatabaseContext.java:4743) at
    >>> com.webobjects.eoaccess.EODatabaseContext.prepareForSaveWithCoordina
    >>> tor(EODatabaseContext.java:5860) at
    >>> com.webobjects.eocontrol.EOObjectStoreCoordinator.saveChangesInEditi
    >>> ngContext(EOObjectStoreCoordinator.java:409) at
    >>> com.webobjects.eocontrol.EOEditingContext.saveChanges
    >>> (EOEditingContext.java:3226) at RequestEditor.submitRequest
    >>> (RequestEditor.java:196)
    >>> ...
    >>>
    >>> As you can see, it is having trouble finding the model file. I
    >>> suspect that it had to do with the name of the model file not
    >>> being the default name. Any suggestions?
    >>>
    >>> Calven
    >>>
    >>> _______________________________________________
    >>> Do not post admin requests to the list. They will be ignored.
    >>> Webobjects-dev mailing list (Webobjects-de..ists.apple.com)
    >>> Help/Unsubscribe/Update your Subscription:
    >>> http://lists.apple.com/mailman/options/webobjects-dev/
    >>> programmingosx%40mac.com
    >>>
    >>> This email sent to programmingos..ac.com
    >>>
    >>
    >>
    >>
    >> --
    >>
    >> It's like driving a car at night. You never see further than your
    >> headlights, but you can make the whole trip that way.
    >>
    >>
    >>
    >> E. L. Doctorow
    >>
    >>
    >>
    >> from Sunbeams: http://www.thesunmagazine.org
    >>
    >>
    >>
    >>
    >
    > _______________________________________________
    > Do not post admin requests to the list. They will be ignored.
    > Webobjects-dev mailing list (Webobjects-de..ists.apple.com)
    > Help/Unsubscribe/Update your Subscription:
    > http://lists.apple.com/mailman/options/webobjects-dev/chill%
    > 40global-village.net
    >
    > This email sent to chil..lobal-village.net

    -- 
    

    Practical WebObjects - for developers who want to increase their overall knowledge of WebObjects or who are trying to solve specific problems. http://www.global-village.net/products/practical_webobjects



    This archive was generated by hypermail 2.0.0 : Thu Jun 07 2007 - 13:24:37 EDT