?
Solved

problem with Collapsable Header

Posted on 2011-03-16
13
Medium Priority
?
344 Views
Last Modified: 2012-05-11
Hi Expert,
In my code i am using option called [Command Description Suggestion/Correction]. When i click that , it opens TextArea with two buttons. when i click again, TextArea with two buttons closes.
Here is the issue:
----------------------
Please see attached screen shots.
expand one CollapsableHeader(cmdName2)--> expand and close [Command Description Suggestion/Correction]-->now collapse the CollapsableHeader(cmdName2)-->again  expand(cmdName2)-->i see singleline with 2 buttons in the bottom
Actually, when i expand CollapsableHeader(cmdName2), TextArea with two buttons should not visible. For the first time it is ok. problem occurs when i open and close  [Command Description Suggestion/Correction]

Could you plse let me know where i am wrong and where i need to change.
Please find my attached component code.

img1.bmp
img2.bmp
img3.bmp
CommandHelpComp.txt
0
Comment
Question by:Alpita
  • 7
  • 6
13 Comments
 
LVL 29

Expert Comment

by:dgofman
ID: 35152841
I will suggest remove your onSuggestionClick function and use

this.currentState = "expand";

in your code.

Now add these lines:

      <s:states>
            <s:State name="default"/>
            <s:State name="expand"/>
      </s:states>

And definefor all "expand" components an attribute

includeIn="expand"


When you click the next time you need to change currentState to "default"

or you can use OR condition:

currentState = (currentState == "expand" ? "default" : "expand");
0
 

Author Comment

by:Alpita
ID: 35153455
I changed like this as per your response.
I Commented the code in the onSuggestionClick ().
But Commented code is needed.
Could you plse let me know, what else i need to change?
changedCode.txt
0
 
LVL 29

Expert Comment

by:dgofman
ID: 35153648
I cannot run your sample file.
But you need remove all

includeInLayout="false"

and use includeIn + state instead

create a simple button and check how your code will work on calling onSuggestionClick function
 
<mx:Button click="onSuggestionClick(event)"/>
0
Enhanced Intelligibility Without Cable Clutter

Challenge: The ESA office in Brussels wanted a reliable audio conference system for video conferences. Their requirement - No participant must be left out from the conference and the audio quality must not be compromised.

 

Author Comment

by:Alpita
ID: 35156989
I ran it. But when i click , TextArea with two buttons are not showing.
I mean currentState statement is not executing properly. Nothing is showing when i click.
Can i have your email id, so that i can attach my files?

Regards,
Alpita
0
 
LVL 29

Expert Comment

by:dgofman
ID: 35158198
Yes, please send me your project I will able to help you.
0
 

Author Comment

by:Alpita
ID: 35158736
Please , could you provide your emailId?
0
 
LVL 29

Expert Comment

by:dgofman
ID: 35158785
david_gofman@yahoo.com
0
 

Author Comment

by:Alpita
ID: 35160254
I sent all my files .
0
 

Author Comment

by:Alpita
ID: 35162110
Hello expert,

I found work around solution. Thanks for your help.

Regards,
Alpita
0
 
LVL 29

Expert Comment

by:dgofman
ID: 35162113
are you using state manager?
0
 

Author Comment

by:Alpita
ID: 35162127
No. I did not use state manager. In onResult(), i made the <mx:VBox/> containing textArea and button visible = false;includeInLayout = false.
I have no idea about states. Need to go through material.

Regards,
Alpita
0
 
LVL 29

Accepted Solution

by:
dgofman earned 2000 total points
ID: 35162304
0
 

Author Closing Comment

by:Alpita
ID: 35162393
Thanks
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

First things first - Preparation We need all the part for this install and it's much nicer to have them all on hand when you need them so here's what's required. Download Eclipse 3.5 32 bit (I like the Classic flavour) from here. (http://www.e…
Last month Marc Laliberte, WatchGuard’s Senior Threat Analyst, contributed reviewed the three major email authentication anti-phishing technology standards: SPF, DKIM, and DMARC. Learn more in part 2 of the series originally posted in Cyber Defense …
Please read the paragraph below before following the instructions in the video — there are important caveats in the paragraph that I did not mention in the video. If your PaperPort 12 or PaperPort 14 is failing to start, or crashing, or hanging, …
With just a little bit of  SQL and VBA, many doors open to cool things like synchronize a list box to display data relevant to other information on a form.  If you have never written code or looked at an SQL statement before, no problem! ...  give i…
Suggested Courses

807 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question