I'll play with the config file and let you know what I find...thanks
again for the help!  Gotta love these things that you spend days on with
no obvious cause...grrr!  Thanks again!

Cheers,

robert l. brueckmann
vice president
merlin securities
595 madison avenue
new york, ny 10022
p: 212.822.4821
f: 212.822.4820

-----Original Message-----
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Simon Fifield
Sent: Tuesday, April 25, 2006 1:52 PM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] Re: Flex 1.5 - Cairngorm .99 - Binding VO to
TextInput help please

Hi Robert,

Although on the surface of things our problems were not the same, I'll
bet
it's the same thing somewhere under the hood of the Flex 1.5 compiler
that
is causing these "strange" binding problems to occur.

I keep reading of more and more people that are encountering this
binding/compilation bug.

Have you tried changing your flex-config.xml settings to not keep the
compiled mxml components:

       <!-- cache compiled custom components as swo files -->
        <cache-swos>false</cache-swos>

And maybe try some of the other cache/compiling settings to see if this
resolves your problem. Compiling may be a little slower but it may be a
better workaround than you currently have.


With the growing number of people having these "mysterious" problems I
wonder if Adobe are going to release an update to resolve them.


Regards,
Simon



-----Original Message-----
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Robert Brueckmann
Sent: 25 April 2006 18:19
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] Re: Flex 1.5 - Cairngorm .99 - Binding VO to
TextInput help please

Thanks for taking the time for the detailed reply Simon!  I WISH it was
validator related.  In one instance, I am using a validator but the
first
time I saw this behavior was in a simple MXML file that had 3 lists that
get
populated with 3 separate message types and directly next to the lists
is a
title label and a text area...when the user clicks on a message in any
of
the 3 lists, the title and text area should be updated with the selected
message's title and body content.

The title label and body text area have their text attributes bound to
{ModelLocator.selectedMessage.title} and
{ModelLocator.selectedMessage.body}
respectively and the change listener on all 3 of the lists is simple
ModelLocator.selectedMessage = event.target.selectedItem;

This NEVER works upon first compilation after a fresh server restart.
If I 'touch' the file that contains this message reader component and
refresh my browser...magically, the title and body start appearing when
I
select a message in the lists.

This behavior escapes me and is obviously not conducive to a production
release because I can't exactly go in and 'touch' all necessary files
for
this behavior to be fixed...this should work the first time.

I even have a test button on the message reader page that, upon first
time
server start and app compilation, when I click on a message and the
ModelLocator.selectedMessage object have been set but the title and body
do
not appear, I can click on this button and in an alert body display the
title and the body of the selectedMessage object...I am confirming the
selectedMessage object is getting set with the proper information, the
damn
TextInput components do not want to show it to me though...if I open up
FlexBuilder, open up my MessagerReader.mxml file, hit the spacebar,
backspace and then save it, refresh my browser...magically it all works
properly.  It's that initial load that is completely baffling me.

I've tried debugging and because my components are being created as
children
on the fly it doesn't see the breakpoints I'm setting up.  I'm at a
loss.

My work around, and this is the kicker, if I take the two fields that
currently, in the same component, reside next to the 3 lists, and wrap
them
up into their own MXML file component and add a COMPLETELY EMPTY

public function set message(m:Message){}

method call in this new wrapped up component and then in the original
message reader component, do this:

<comp:MessageReaderFields width="100%" height="100%"
message="{ModelLocator.selectedMessage}" />

And now, when I select a message, first compilation, 14th compilation,
1st
server restart, 10th server restart, the message title and body field
binding to the ModelLocator.selectedMessage object in my new embedded
component work as they should.  Makes sense, right?  Nope.  Not even a
little bit.

Whatever...looks like I have a work-around for the time being...

robert l. brueckmann
vice president
merlin securities
595 madison avenue
new york, ny 10022
p: 212.822.4821
f: 212.822.4820

-----Original Message-----
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Simon Fifield
Sent: Tuesday, April 25, 2006 11:33 AM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] Re: Flex 1.5 - Cairngorm .99 - Binding VO to
TextInput help please

Are/have you used a validator with a bound field anywhere in this file?

If so you may be experiencing the same problem as I did. I wasted days
trying to figure out why my Binding had suddenly broken down on several
forms. I was using about 6 or 7 validators per form and the fields in
the
forms were using binding which should be no problem. However the binding
just stopped working and I tried for days to get it to work again. In
the
end I got it working by commenting out nearly all of the mxml content
and
when it started working again I uncommented it and it worked, but then
guess
what - it stopped working again.

Libby kindly gave me some pointers and mentioned that you must use the
"listener" attribute of the Validator tag to explicitly target the field
that you want to validate.

I'm not certain if her solution works but give it a go.

I found a workaround by using just 1 Validator for the entire form and
using
a custom validation function.

      <mx:Validator field="checkContact"
validate="contactVH.validateForm(event.validator, event.value)" />

Then your validate function could be:

      function validateForm( validator, value ) : Void {        

            if ( value.firstname=="" || value.firstname==undefined )
{
                  validator.validationError("firstnameMissing",
"You
must enter the firstname", "firstname");
            }

            if ( value.lastname=="" || value.lastname==undefined ) {
                  validator.validationError("lastnameMissing",
"You
must enter the lastname", "lastname");
            }

            EmailValidator.validateEmail( validator, value.email,
null,
"email" );
     
            if ( value.telephone=="" || value.telephone==undefined )
{
                  validator.validationError("telephoneMissing",
"You
must enter the landline telephone number", "telephone");
            }

            if ( value.addrstreet=="" || value.addrstreet==undefined
) {
                  validator.validationError("addrstreetMissing",
"You
must enter the street address", "addrstreet");
            }

            if ( value.addrcity=="" || value.addrcity==undefined ) {
                  validator.validationError("addrcityMissing",
"You
must enter the city address", "addrcity");
            }

            if ( value.addrpostcode=="" ||
value.addrpostcode==undefined
) {
                  validator.validationError("addrpostcodeMissing",
"You must enter the post code", "addrpostcode");
            }

      }

Its not at all efficient because I validate the form on every change of
every field so there is lots of testing going on - but that's because I
need
it to highlight errors as they are being typed or being resolved

This seems to work for me.

If you are not experiencing the Validator/Binding problem - ignore all
of
this!

Regards,
Simon




-----Original Message-----
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Suzy Lawson
Sent: 25 April 2006 14:17
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Flex 1.5 - Cairngorm .99 - Binding VO to
TextInput
help please

Have you tried debugging? set a breakpoint in your onResult of the
Command
class and where you explictly set the selectedUser in the model locator.
Once that line has passed, you should stop again then check your text
box to
see if it has the value. I find I get a lot further debugging then using
trace statements. Then repeat the process with the second hit when the
behavior works OK. This should hopefully identify your issue.

--- In flexcoders@yahoogroups.com, "Robert Brueckmann"
<[EMAIL PROTECTED]> wrote:
>
> Thanks Suzy but my problem isn't with populating a combobox...my
> combobox of users populates just fine, when I select a user from the
> list and the user is fetched, the user object whose fields are
bound to
> various textinput fields in my form are not shown...it's only when I
> 'touch' the file and refresh my browser, is the user information
shown
> correctly in the textinput components of my form...I can't grasp why
> this would be happening...
>
> robert l. brueckmann
> vice president
> merlin securities
> 595 madison avenue
> new york, ny 10022
> p: 212.822.4821
> f: 212.822.4820
> -----Original Message-----
> From: flexcoders@yahoogroups.com
[mailto:[EMAIL PROTECTED] On
> Behalf Of Suzy Lawson
> Sent: Monday, April 24, 2006 7:32 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: Flex 1.5 - Cairngorm .99 - Binding VO to
> TextInput help please
>
> Roger,
>   I have faced the same problem. The reason is that when you deploy
it
> the server for the first time, nothing is compiled. So in your
initial
> request, your application returns the users before it has compiled
and
> created the component...so your call to set the combo box with user
> silenty fails. When you hit refresh, since everything is already
> compiled, it can set the combobox with the data in time.
>
> Put your logic to fetch the XML user in the creationComplete method
of
> your mx:Combobox...or somewhere where you know it is created.
>
> hope this helps. cheers.
>
> --- In flexcoders@yahoogroups.com, "Robert Brueckmann"
> <rbrueckmann@> wrote:
> >
> > I tried searching the archives and couldn't find anything
relevant to
> > what we're doing here, so I'm hoping someone can explain
something:
> >
> > 
> >
> > 
> >
> > 1.      User logs in
> >
> > 2.      XML is returned with all applications user has access to
> >
> > 3.      Tab Navigator component is generated on the fly with tabs
> > labeled according to application names in XML returned from DB.
> Actual
> > MXML component each tab is linked to is not yet created upon
creation
> of
> > the TabNavigator...ONLY when the user clicks on a tab, is the
> > appropriate MXML component created.
> >
> > 4.      One of the tabs is a user admin form where an admin user
can
> > select any of the system users from a list and edit their
information
> >
> > 5.      All fields in this form are bound to
> > ModelLocator.selectedUser.someField
> >
> > 6.      Admin user selects user from list and in the result
method of
> my
> > command class that retrieves the user, the code is simply
> > ModelLocator.selectedUser = UserAdminVO(event.result);
> >
> > 7.      The VERY first time the application is deployed and the
> > application server restarted, and the application compiles for the
> first
> > time, the TextInput components DO not get updated with the bound
> > selectedUser's information.  My trace statements in the command
class
> > SHOW the selectedUser object getting set and the field values
there,
> but
> > my TextInput components do not reflect this information.
> >
> > 8.      If I open up FlexBuilder and open my UserAdmin.mxml file,
> simply
> > hit the spacebar, and save it (the file is automatically uploaded
to
> my
> > app server) and I hit the refresh button on my browser, go to the
User
> > Admin tab and select a user, magically, the user info is
displayed as
> it
> > should.
> >
> > 9.      If I try to redploy the code and restart the app server
again,
> > I'm back to square one.
> >
> > 
> >
> > 
> >
> > What the HECK is going on here?  It's like a bug in the binding
of a
> VO
> > to the TextInput components does not work upon initial
compilation on
> > dynamically created components...not until I TOUCH the component
MXML
> > file and refresh the browser, forcing the Flex compiler to
recompile
> the
> > app, do the fields actually show the properly bound information.
> >
> > 
> >
> > Any thoughts?
> >
> > 
> >
> > robert l. brueckmann
> >
> > vice president
> >
> > merlin securities
> >
> > 595 madison avenue
> >
> > new york, ny 10022
> >
> > p: 212.822.4821
> >
> > f: 212.822.4820
> > 
> > --------------------------------------------------------
> >
> > This message contains information from Merlin Securities, LLC, or
> from one of its affiliates, that may be confidential and privileged.
> If you are not an intended recipient, please refrain from any
> disclosure, copying, distribution or use of this information and
note
> that such actions are prohibited. If you have received this
> transmission in error, please notify the sender immediately by
> telephone or by replying to this transmission.
> > 
> > Merlin Securities, LLC is a registered broker-dealer. Services
> offered through Merlin Securities, LLC are not insured by the FDIC
or
> any other Federal Government Agency, are not deposits of or
guaranteed
> by Merlin Securities, LLC and may lose value. Nothing in this
> communication shall constitute a solicitation or recommendation to
buy
> or sell a particular security.
> >
>
>
>
>
>
>
> --
> Flexcoders Mailing List
> FAQ:
http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> Search Archives:
> http://www.mail-archive.com/flexcoders%40yahoogroups.com
> Yahoo! Groups Links
>
>
>

> --------------------------------------------------------
>
> This message contains information from Merlin Securities, LLC, or
from one of its affiliates, that may be confidential and privileged.
If you are not an intended recipient, please refrain from any
disclosure,
copying, distribution or use of this information and note that such
actions
are prohibited. If you have received this transmission in error, please
notify the sender immediately by telephone or by replying to this
transmission.

> Merlin Securities, LLC is a registered broker-dealer. Services
offered through Merlin Securities, LLC are not insured by the FDIC or
any
other Federal Government Agency, are not deposits of or guaranteed by
Merlin
Securities, LLC and may lose value. Nothing in this communication shall
constitute a solicitation or recommendation to buy or sell a particular
security.
>







--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.com
Yahoo! Groups Links










--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.com
Yahoo! Groups Links




--------------------------------------------------------

This message contains information from Merlin Securities, LLC, or from
one
of its affiliates, that may be confidential and privileged. If you are
not
an intended recipient, please refrain from any disclosure, copying,
distribution or use of this information and note that such actions are
prohibited. If you have received this transmission in error, please
notify
the sender immediately by telephone or by replying to this transmission.

Merlin Securities, LLC is a registered broker-dealer. Services offered
through Merlin Securities, LLC are not insured by the FDIC or any other
Federal Government Agency, are not deposits of or guaranteed by Merlin
Securities, LLC and may lose value. Nothing in this communication shall
constitute a solicitation or recommendation to buy or sell a particular
security.


--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.com
Yahoo! Groups Links










--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.com
Yahoo! Groups Links




--------------------------------------------------------

This message contains information from Merlin Securities, LLC, or from one of its affiliates, that may be confidential and privileged. If you are not an intended recipient, please refrain from any disclosure, copying, distribution or use of this information and note that such actions are prohibited. If you have received this transmission in error, please notify the sender immediately by telephone or by replying to this transmission.

Merlin Securities, LLC is a registered broker-dealer. Services offered through Merlin Securities, LLC are not insured by the FDIC or any other Federal Government Agency, are not deposits of or guaranteed by Merlin Securities, LLC and may lose value. Nothing in this communication shall constitute a solicitation or recommendation to buy or sell a particular security.


--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com




SPONSORED LINKS
Web site design development Computer software development Software design and development
Macromedia flex Software development best practice


YAHOO! GROUPS LINKS




Reply via email to