Re: Newbie question about highlighting rows
Re: Newbie question about highlighting rows
- Subject: Re: Newbie question about highlighting rows
- From: Chip Myers <email@hidden>
- Date: Tue, 25 Jul 2006 09:35:35 -0700 (PDT)
Sacha: you mentioned
Then, inside the repetition, modify the tag to be
NAME=HighlightConditional>style="background: grey;">,
where HighlightConditional is a WOConditional bound to a method that
returns true only when the selected index equals the current index.
How do I call this method to check for when the selected index equals the current index? Should I place a WOGenericElement which calls the method inside my row, so that the check can be performed on each iteration of the repetition? I have a feeling that there are more efficient ways, I just don't know them yet.
Thanks,
Mike
email@hidden wrote:
Send Webobjects-dev mailing list submissions to
email@hidden
To subscribe or unsubscribe via the World Wide Web, visit
http://lists.apple.com/mailman/listinfo/webobjects-dev
or, via email, send a message with subject or body 'help' to
email@hidden
You can reach the person managing the list at
email@hidden
When replying, please edit your Subject line so it is more specific
than "Re: Contents of Webobjects-dev digest..."
Today's Topics:
1. Re: Obtaining Application Instance Number (Robert Campbell)
2. Re: JDBCChannel method failed to update (Kieran Kelleher)
3. EOObjectNotAvailableException (Watkins, Garry)
4. Re: EOObjectNotAvailableException (Ken Anderson)
5. RE: EOObjectNotAvailableException (Watkins, Garry)
6.
Re: Newbie question about highlighting rows (Sacha Michel Mallais)
----------------------------------------------------------------------
Message: 1
Date: Tue, 25 Jul 2006 15:43:43 +0100
From: Robert Campbell
Subject: Re: Obtaining Application Instance Number
To: Mike Schrag
Cc: "email@hidden Apple"
Message-ID: <email@hidden>
Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed
Hi Mike,
Thanks for the info, Ideally I would like to get the id when the
application is instantiated rather than in response to a request, but
its a useful call and I may be able work that way round.
Thanks,
Rob.
On 25 Jul 2006, at 12:05, Mike Schrag wrote:
> context.applicationNumber()
>
> On Jul 25, 2006, at 5:29
AM, Robert Campbell wrote:
>
>> Hi All,
>>
>> Does anyone know how I can get the application instance number? -
>> I need to programmatically construct URLs
>> that contain the application instance number for load balancing
>> e.g. for the URL http://www.mydomain.com/cgi-bin/WebObjects/
>> myapp.woa/1/wa/nextPage?
>> I need to insert the application instance number between "http://
>> www.mydomain.com/cgi-bin/WebObjects/myapp.woa/" and "/wa/nextPage?"
>> I've gone through all the documentation and can obtain just about
>> every other application property but can't get the instance ID.
>> Any gurus out there know how it can be done?
>>
>> Rob.
>> _______________________________________________
>> Do not post admin requests to the list. They will be ignored.
>> Webobjects-dev mailing list
email@hidden
Message-ID:
Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed
Log out the exception.userInfo() dictionary to see what the actual
error message was that the database server returned.
On Jul 25, 2006, at 4:20 AM, Corin Lawson wrote:
> Hi List,
>
> As volume has increased on our woapp so has the occurrence of this
> particular error, below. I am using WO 5.2.4 with MySQL 5.0.
>
> com.webobjects.eoaccess.EOGeneralAdaptorException:
> updateValuesInRowDescribedByQualifier --
> com.webobjects.jdbcadaptor.JDBCChannel method failed to update row
> in database
> at
> com.webobjects.eoaccess.EODatabaseContext._exceptionWithDatabaseContex
> tInformationAdded(EODatabaseContext.java:4685)
> at com.webobjects.eoaccess.EODatabaseContext.performChanges
email@hidden
------------------------------
Message: 3
Date: Tue, 25 Jul 2006 10:57:12 -0400
From: "Watkins, Garry"
Subject: EOObjectNotAvailableException
To:
Message-ID:
<email@hidden>
Content-Type: text/plain; charset="us-ascii"
I am getting EOObjectNotAvailableException when I have optional
relationships that are linked by a primary key. I do not control the
data entry that is associated with these records, so I cannot
automatically create empty ones Is there a way for me to trap these
exceptions and just get a null back.
This is a run down of my scenario:
I have Client, ClientExtensionAsbestos, ClientExtensionSilica entities.
They all have a primary key of A_Client. Both of the Extension entities
are optional depending on the clients case type. A client may
have one
or more extension records but they are all optional relationships. If I
trigger the fault extensionSilica (or any other extension) and it does
not exist, I want to receive null back.
Any pointers would be appreciated.
Thanks,
Garry
Confidential & Privileged
Unless otherwise indicated or obvious from its nature, the information contained in this communication is attorney-client privileged and confidential information/work product. This communication is intended for the use of the individual or entity named above. If the reader of this communication is not the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communication in error or are not sure whether it is privileged, please immediately notify us by return e-mail and destroy any copies--electronic, paper or otherwise--which you
may have of this communication.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.apple.com/pipermail/webobjects-dev/attachments/20060725/330264cb/attachment.html
------------------------------
Message: 4
Date: Tue, 25 Jul 2006 11:07:36 -0400
From: Ken Anderson
Subject: Re: EOObjectNotAvailableException
To: "Watkins, Garry"
Cc: email@hidden
Message-ID: <email@hidden>
Content-Type: text/plain; charset="us-ascii"
Garry,
EOF is not happy with such situations - if the key is not null, it
expects the to-one to exist.
There are a few workarounds - the simplest is to turn the
relationship into a to-many and check the object count before
returning null or the one object in the array.
Ken
On Jul 25, 2006, at 10:57 AM,
Watkins, Garry wrote:
> I am getting EOObjectNotAvailableException when I have optional
> relationships that are linked by a primary key. I do not control
> the data entry that is associated with these records, so I cannot
> automatically create empty ones Is there a way for me to trap
> these exceptions and just get a null back.
>
> This is a run down of my scenario:
>
> I have Client, ClientExtensionAsbestos, ClientExtensionSilica
> entities. They all have a primary key of A_Client. Both of the
> Extension entities are optional depending on the clients case
> type. A client may have one or more extension records but they are
> all optional relationships. If I trigger the fault extensionSilica
> (or any other extension) and it does not exist, I want to receive
> null back.
>
> Any pointers would be appreciated.
>
> Thanks,
>
Garry
>
> Confidential & Privileged
>
> Unless otherwise indicated or obvious from its nature, the
> information contained in this communication is attorney-client
> privileged and confidential information/work product. This
> communication is intended for the use of the individual or entity
> named above. If the reader of this communication is not the
> intended recipient, you are hereby notified that any dissemination,
> distribution or copying of this communication is strictly
> prohibited. If you have received this communication in error or
> are not sure whether it is privileged, please immediately notify us
> by return e-mail and destroy any copies--electronic, paper or
> otherwise--which you may have of this communication.
>
> _______________________________________________
> Do not post admin requests to the list. They will be
and it
encounters a EOObjectNotAvailableException it should return null.
However, I want to continue to use EOGenericRecords since it is mainly a
reporting type application. Does anyone know where the Fault is
triggered inside the EO stack so that I might be able to trap the
operation with AspectJ? This would also require that I have the
EORelationship that triggered the fault.
Thanks
Garry
________________________________
From: Ken Anderson [mailto:email@hidden]
Sent: Tuesday, July 25, 2006 11:08 AM
To: Watkins, Garry
Cc: email@hidden
Subject: Re: EOObjectNotAvailableException
Garry,
EOF is not happy with such situations - if the key is not null, it
expects the to-one to exist.
There are a few workarounds - the simplest is to turn the relationship
into a to-many and check the object count before returning null or the
one object in the
array.
Ken
On Jul 25, 2006, at 10:57 AM, Watkins, Garry wrote:
I am getting EOObjectNotAvailableException when I have optional
relationships that are linked by a primary key. I do not control the
data entry that is associated with these records, so I cannot
automatically create empty ones Is there a way for me to trap these
exceptions and just get a null back.
This is a run down of my scenario:
I have Client, ClientExtensionAsbestos, ClientExtensionSilica
entities. They all have a primary key of A_Client. Both of the
Extension entities are optional depending on the clients case type. A
client may have one or more extension records but they are all optional
relationships. If I trigger the fault extensionSilica (or any other
extension) and it does not exist, I want to receive null back.
Any pointers would be appreciated.
Thanks,
Garry
Confidential &
Privileged
Unless otherwise indicated or obvious from its nature, the
information contained in this communication is attorney-client
privileged and confidential information/work product. This communication
is intended for the use of the individual or entity named above. If the
reader of this communication is not the intended recipient, you are
hereby notified that any dissemination, distribution or copying of this
communication is strictly prohibited. If you have received this
communication in error or are not sure whether it is privileged, please
immediately notify us by return e-mail and destroy any
copies--electronic, paper or otherwise--which you may have of this
communication.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list
(email@hidden)
Help/Unsubscribe/Update your Subscription:
show the structure is as follows:
>
> SELECT PERSON A CITY A STATE A
> ________________________________________
>
> SELECT PERSON B CITY B STATE B
> ________________________________________
>
> SELECT PERSON C CITY C STATE C
>
> Upon clicking the 'select' hyperlink, I'd like to highlight this
> entire row, and only this row. Unfortunately, I end up
> highlighting the entire table when the page refreshes itself. I
> should add that I have an alternating white and gray row pattern
> which is generated from a few session variables. Since this occurs
> in the session, I've also tried creating a session flag called
> boolThisRowSelected, to determine when the highlight should occur,
> but it just hasn't worked yet.
>
> Is there an easy way to highlight just one row within a
> WORepetition without having to
create more session variables?
You can't highlight a row only using WORepetition, nor should you be
using the session to store temporary (page-based) information.
I would do the following (note that this assumes you are alright with
the page reloading in order to accomplish the row highlight): first,
add an index binding to the repetition. Then, inside the repetition,
modify the tag to be
NAME=HighlightConditional>style="background: grey;">,
where HighlightConditional is a WOConditional bound to a method that
returns true only when the selected index equals the current index.
Finally, modify the action method that the SELECT hyperlink is bound
to so that it sets the selected index when it is clicked.
HTH,
sacha
--
Sacha Michel Mallais Senior Developer / President
Global Village Consulting Inc. http://www.global-village.net/
PGP
Key ID: 7D757B65 AIM: smallais
------------------------------
_______________________________________________
Webobjects-dev mailing list
email@hidden
http://lists.apple.com/mailman/listinfo/webobjects-dev
End of Webobjects-dev Digest, Vol 3, Issue 466
**********************************************
_______________________________________________
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