Disable widgets in a dialog when checkbox is clicked...

Hi,
I m using InDesign CS3 on MAC OS.
I have created a dialog with 2 textfields and a checkbox. I want only one of the textfields to be visible at a time...
That is, depending on the value of the checkbox(1 or 0), i have to disable the textfileds. Initially only textfield1 is active, and on checking the checkbox, textfield2 becomes active and textfield1 gets disabled.
Where should i give my code? For disabling operations we use SuppressedUI.h.
I tried this:
bool16    BscDlgSuppressedUI::IsWidgetDisabled( const IControlView* widget ) const
   InterfacePtr<IWidgetParent> widgetParent(this, UseDefaultIID());
    ASSERT(widgetParent);
    InterfacePtr<IPanelControlData> panelControlData((IPanelControlData*)(widgetParent->QueryParentFor(IPanelControlData::kDe faultIID)));
    ASSERT(panelControlData);
    IControlView* iControlView = panelControlData->FindWidget(kBscDlgVisibleCheckBoxWidgetID);
    InterfacePtr<ITriStateControlData> TriStateControlData(iControlView, UseDefaultIID());
    bool16 y = TriStateControlData->IsSelected();
    if(y)
        WidgetID widgetID = GetWidgetID(widget);
        switch (widgetID.Get())
            case kBscDlgTextEditBoxWidgetID:
                return kTrue;
But this leads to application crash on launching it itself. I think it may be becausu of trying to get the values of widgets in a diallog when the dialog is not visible. Donno if i m right...
Where should i give the code? can i call this BscDlgSuppressedUI::IsWidgetDisabled() method from the dialog controller?How?
Can someone pls help with code snippet..
Pls guide me..
Thank You.

Thanks for ur reply Schneider..
I already have an observer for my dialog..
Should i give my code in  BscDlgDialogObserver::Update() method?
How to turn on/off the texteditfields????

Similar Messages

  • How do I disable the brushes popup menu when I left click in Photoshop CS5?

    How do I disable the brushes popup menu when I left click in Photoshop CS5? I am trying to use the clone stamp and I am not able to get a sample because of this popup menu.

    LOL,  I can't even begin to complain with the number if times I misread questions, and then try to break my own record for the number of typos in a single post.
    The image above was taken on a photgraphic weekend where the group (of all young ladies ) I was travelling with, set us a photography challenge.  The one above was my response to a 'faceless portrait'.  The only other one I attempted was this response for a picture of a 'wild animal', featuring camera club president Liz.
    Oh what fun we had, laughing and laughing until our faces fell off.
    [EDIT]  Both taken at Karamea, which some visitors to NZ might recognise as the western end of the Heaphy Track.

  • How to disable row in tabular form when checkbox checked?

    Hi.... this is what i want to do....
    I created tabular form for offering items... there is a checkbox that is used to select item with lowest price...
    But i have also one column that shows item options ( option is for example... i want offer for 22" monitor Samsung, but seller have only 22" LG monitor.... so in my offering will be shown item (22" monitor Samsung) that i want, and in row below item (22" LG monitor) that seller have... both items will have same order id....
    Next thing i want to do is when i select checkbox with item (22" LG monitor) as lowest price, i want that row with same order id (22" samsung monitor) is disabled.
    Is that possible to do?
    This is my code for creating tabular form:
    SELECT
    CASE WHEN RED_BR_OPCIJE = 0 THEN '-' ELSE TO_CHAR(RED_BR_OPCIJE) END RED_BR_OPCIJE,
    apex_item.hidden(1, ID_STAVKE)||
    apex_item.hidden(2, ID_STAVKE_IZ_ZAHTJEVA)||           ---order_id
    apex_item.hidden(3, ID_PONUDE)||
    apex_item.hidden(4, ODABIR_NAJPOVOLJNIJE_STAVKE)||     
    apex_item.checkbox(5, '#ROWNUM#', null, decode(ODABIR_NAJPOVOLJNIJE_STAVKE, 'X', '#ROWNUM#')) Odabir,    ---checkbox_lowest price
    apex_item.textarea(6, NAZIV_ARTIKLA_TRAZENO, 3, 40, 'readonly="readonly"') NAZIV_ARTIKLA_TRAZENO,
    apex_item.textarea(7, NAZIV_ARTIKLA, 3, 40, 'readonly="readonly"') NAZIV_ARTIKLA,
    apex_item.text(8, SIFRA_ARTIKLA, 8, 20, 'readonly="readonly"') SIFRA_ARTIKLA,
    apex_item.text(9, JMJ, 5, 20, 'readonly="readonly"') JMJ,
    apex_item.text(10, KOLICINA, 6, 20, 'readonly="readonly"') KOLICINA,
    apex_item.text(11, JEDINICNA_CIJENA, 12, 20, 'readonly="readonly"') JEDINICNA_CIJENA,                                      ---price
    apex_item.text(12, IZNOS_STAVKE, 12, 30, 'readonly="readonly"') IZNOS_STAVKE,
    apex_item.text(13, IZNOS_RABATA, 12, 20, 'readonly="readonly"') IZNOS_RABATA,
    apex_item.text(14, JEDINICNA_CIJENA_NAKON_POPUSTA, 12, 20, 'readonly="readonly"') JEDINICNA_CIJENA_NAKON_POPUSTA,
    apex_item.text(15, IZNOS_STAVKE_NAKON_POPUSTA, 12, 20, 'readonly="readonly"') IZNOS_STAVKE_NAKON_POPUSTA
    from PONUDE_STAVKE
    where ID_PONUDE = :P34_ID_PON
    ORDER BY ID_PONUDE ASC, ID_STAVKE_IZ_ZAHTJEVA ASC, RED_BR_OPCIJE ASC
    And this is example table with a few column names:
    order_id      option_number               item_name                      price         checkbox_lowest price
    1086                    -                Samsung 22" monitor              100$                 null                ---this row should be disabled because next row is selected as lowest price
    1086                    1                LG 22" Monitor                    90$                 X                   --- both rows have same order_id
    1050                    -                Router                            100$                X

    Hi snake2903,
    {thread:id=998140}
    {thread:id=1554583}
    {thread:id=2249233}
    Hope it helps!
    Regards,
    Kiran

  • Easily set column value in table's row when checkbox is clicked

    Hi,
    in Jdev 11.1.2.3 i have a table which row consists of 2 columns:
    How can i set value #{securityContext.userName} to it1 in column 2 when soc1 is changed in column 1?
    I can see a way to do to define <af:setPropertyListener on soc, then find currentRow in BB and set the respective attribute in VO.
    Can anyone suggest an easier approach, a shortcut to one from above? i feel there are some... :-)
    Use a clientListener ?
    <af:column sortProperty="#{bindings.V1.hints.Selected.name}" sortable="false"
    headerText="" id="c1" width="30">
    <af:selectBooleanCheckbox value="#{row.bindings.Selected.inputValue}"
    label="#{row.bindings.Selected.label}"
    shortDesc="#{bindings.V1.hints.Selected.tooltip}" id="sbc1"/>
    </af:column>
    <af:column headerText="#{bindings.V1.hints.ProcessedUser.label}" id="c17">
    <af:inputText value="#{row.bindings.ProcessedUser.inputValue}" it1
    </af:column>

    Frank,
    i've created an attrBinding in pagedef af:setPropertyListener type attribute:
    the only one allowed id attributeChange
    but at runtime the error is raised that valueChange is not valid type
    the problem arouse with
    <af:selectBooleanCheckbox value="#{row.bindings.Selected.inputValue}"
    label="#{row.bindings.Selected.label}" autoSubmit="true"
    valueChangeListener="#{registerBean.socSelectedChangeListener}"
    shortDesc="#{bindings.V1.hints.Selected.tooltip}" id="sbc1"/>
    <af:setPropertyListener from="#{securityContext.userName}"
    to="#{bindings.ProcessedUser.inputValue}"
    type="valueChange"/>

  • How to disable the reminding dialog when close the webi report viewer

    Dear all
    How to disable the reminding dialog when close the webi report viewer
    Background
    When user close the webi report viewer in inforview by click the button in the right-top of the webi report viewer frame. It always prompt a dialog to remind user that the modification will be lost without saving.
    But customer need to disable this dialog, and can clost the report viewer directly.
    So is there any ways to modify this?
    I think it shoule modify some .js file under tomcat, but can not find the solution.
    Thanks a lot, any information woulde be appreciated.
    David Zhang

    I've had the same issue bugging me since installing Snow, er, lion, er, cat, er, cougar, er, Mountain Lion. Incredibly ANNOYING.
    It's stupid stuff like this and reverse scrolling that really turn long-timer users off. I'm personally glad Forstall got fired for blunders such as these.
    I'm serious peeved that turning off iCloud Documents & Data actually deletes documents and data locally. That's just incredibly stupid.
    MANY thanks mende1 for the answer on how to fix it.

  • How to turn off brush size dialog when holdng stylus on tablet.

    Yesterday I signed up to try the latest version of Photoshop (CC) from previously working in CS6.
    There is a new behavior that when I hold down my stylus for more than a half-second or so on my tablet, a swirling circle icon appears and then a floating brush size dialog pops up.
    I can't stand this, and want to turn it off or at least edit the settings, but I can't find anything in preferences about it.
    PS CS6 does not have this behavior with the same tablet, so I think it has to do with Photoshop.
    Any ideas?

    Thanks for your reply. Yep, it's engaged. That button is very important to me. lol
    This definitely seems like a Photoshop CC feature, not a tablet issue.
    Here is a screenshot of what I mean:
    That white circle in the upper left corner of the box comes up and "loads" the dialog when I press down on the tablet with my stylus. I just updated my tablet drivers last week.
    This does not happen in Photoshop CS6, which I still have installed and have been using prior to this trial of CC.
    Basically, I would at least like to increase the delay time of how long it takes for me to hold down my stylus before this behavior happens, if not disable it altogether. I don't have  the need for this feature and it gets in my way constantly.

  • How to make a text field required at run time when the user clicks the checkbox ?

    I got a form where , there are several checkboxes and text fields associated with that checkboxes.If the use clicks on the check box then the associated
    text fields should become required.I have tried the change event and the click event for the checkboxes.It gives error in the onChnage event and I got some weird results in the on click event .Sometimes if the user click the check box , then for the 1st time the field doesnt become required , then the user onclicks the check box and when the user clicks the checkbox for the second time the field becomes required,but if i deselects the highlighted field option and selects it again the field becomes required even if the user onchecks it I am totally confused !!! Adding to it i have also written the wrong code still i achieved the desired result ?? How it can be possible . I am writing the codes below , please help me as i am working under a deadline from the client.
    onChange event :
    var newVal = this.boundItem(xfa.event.newText);
    if(newVal == 0)
        xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row4.Purchasecost3_1" ).validate.nullTest = "disabled";
      else
         xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row4.Purchasecost3_1" ).validate.nullTest = "error";
    For the onClick event :
    var a = xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row2.CostItemRecovere d_OnlyEnergyCharges").rawValue;
    //app.alert(a);
    if(a == 0)
        xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row4.ComplianceCheck_ L1_1").validate.nullTest = "error";
      if(a == 1)
          xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row4.ComplianceCheck_ L1_1").validate.nullTest = "disabled";
       Please help someone !!!

    I used the onchange event and wrote the code for it. I got the result . But there is a problem.All these fields are in a table and it's a dynamic table where you can add rows dynamically at the run time .I have other change event for some fields in this table .All are working fine when i add the row.But for this check box the required fields are not validated as required at the run time . I am here giving the code , Please help me .
    form1.Subform0.Subform1.Subform9.Subform10.Table48.Row2.CostItemRecovered_OnlyEnergyCharge s::change - (JavaScript, client)
    if(this.rawValue == "1")
      xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row4.ComplianceCheck_ L1_1").mandatory= "error";
      xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row4.ComplianceCheck_ L2_1").mandatory= "error";
      xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row5.ComplianceCheck_ L1_2").mandatory= "error";
      xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row5.ComplianceCheck_ L2_2").mandatory= "error";
      xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row6.ComplianceCheck_ L1_3").mandatory= "error";
      xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row6.ComplianceCheck_ L2_3").mandatory= "error";
      xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row7.ComplianceCheck_ L1_4").mandatory= "error";
      xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row7.ComplianceCheck_ L2_4").mandatory= "error";
      xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row8.ComplianceCheck_ L1_5").mandatory= "error";
      xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row8.ComplianceCheck_ L2_5").mandatory= "error";
    else
    xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row4.ComplianceCheck_ L1_1").mandator = "disabled";
    xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row4.ComplianceCheck_ L2_1").mandatory = "disabled";
    xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row5.ComplianceCheck_ L1_2").mandatory = "disabled";
    xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row5.ComplianceCheck_ L2_2").mandatory = "disabled";
    xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row6.ComplianceCheck_ L1_3").mandatory = "disabled";
    xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row6.ComplianceCheck_ L2_3").mandatory = "disabled";
    xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row7.ComplianceCheck_ L1_4").mandatory = "disabled";
    xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row7.ComplianceCheck_ L2_4").mandatory = "disabled";
    xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row8.ComplianceCheck_ L1_5").mandatory = "disabled";
    xfa.resolveNode("form1.Subform0.Subform1.Subform9.Subform10.Table48.Row8.ComplianceCheck_ L2_5").mandatory = "disabled";

  • Disable the AirDrop confirmation dialog?

    I frequently use AirDrop to transfer files between iMac and MBA. Is there any way to disable this annoying confirmation dialog, as I am on a secure home network?

    Thanks for your input. I currently have both iMac and MBP set to share over the network, but they seem to only want to connect about 50% of the time...when they don't want to communicate, I can usually use AirDrop, I just would prefer to skip the confirmation dialog (I know you can set the Shared Disk setting to not ask for confirmation)

  • Can't disable option show import dialog w/ memory card detected

    Hello. Across the board, I don't want applications to open up when memory cards or cd/dvds are inserted. Adobe Lightroom counters this desire by opening when I insert a memory card.
    I am running Windows Lightroom 2.4. In pervious versions, I could disable the perferences / import / show import dialog when a memory card is detected. However, in 2.4 I uncheck this option. Close lightroom. Open lightroom. And my disabled selection didn't save. It has it checked. And...Lightroom continues to open when I insert a memory card.
    Any ideas on how to resolve this issue?
    I have tried running Lightroom as admin to see if it was a registry permissions issues. The options still didn't stay unset.
    Thanks for your advice.

    DalePh wrote:
    I am running Windows Lightroom 2.4. In pervious versions, I could disable the perferences / import / show import dialog when a memory card is detected. However, in 2.4 I uncheck this option. Close lightroom. Open lightroom. And my disabled selection didn't save. It has it checked. And...Lightroom continues to open when I insert a memory card.
    You don't say which OX you're running, but if it is a Vista 64 bit version just a few notes down you will find the answer:
    http://forums.adobe.com/thread/455749?tstart=0
    Essentially it is a bug in 2.4 on Vista 64 bit systems and must be fixed by Adobe.
    I do experience the bug on my Vista system but not on my iMac.

  • How do I ensure that when a user clicks a box on the check box widget, the check box remains?

    Hi, I am using Captivate version 7. I am using a Checkbox widget on a slide. When the user checks the check box and then closes out of the course, how do I ensure that when the user goes back into the course, the check box remains? We're posting on an LMS. Thanks!

    Every widget, variable is reset when a course is restarted. Moreover you cannot control what is checked in the Checkbox widget by another action than the user click, even though you can change the value of the associated variable. I think you'll have to look for another solution.

  • Show Confirmaiton Dialog when user closes the browser

    Hello All,
    Can we show a confirmation dialog when user chooses to close the browser in which applet is running? I know that it can be done using javascript. Can it be done using java code?
    Please suggest.
    Thank you.

    teejrama wrote:
    ..Can we show a confirmation dialog when user chooses to close the browser in which applet is running?.. You can pop a JOptionPane in the applet's destroy() method, but that will not do any good, since the browser is not asking the applet for advice on whether it is closing, it is telling the applet it is closing.
    ..I know that it can be done using javascript... Can it? How?
    If so, that would be another good reason to disable JS.
    ..Please suggest.I suggest you presume the end-user is smart enough to know when they want to close their own browser, and not interfere in that process.
    Thank you.No worries.

  • Display save as dialog when downloading a file

    Hi,
    I want to display a save as dialog when the user downloads a file.
    Now I get a dialog where the user can choose to open or save it.
    I set these headers:
    res.setHeader("Content-disposition", "attachment; filename=" + filnamn);
    res.addHeader("Content-Type", "application/force-download");Thanks!

    Sorry!
    When the user downloads a file I want to open a dialog where the user
    can write a filename and then click Save to save the file.
    Today I get a dialog where the user first have to choose if he wants to open or save the file.
    When he clicks save then the dialog appears that I would want to be displayed.
    I hope this clearifies my question.

  • Insert statement in when-checkbox-checked trigger doesn't work

    in a when-checkbox-checked trigger, I wrote the follwing code :
    IF :sunday = 'Y' THEN
    msg_alert('Y','I',false);
    pkg_var.v_day_count := pkg_var.v_day_count + 1;
    msg_alert('1','I',false);
    :schtm_skmk.day_id := '1';
    msg_alert('2 ',I',false);
    INSERT INTO schtm      
    (ROUTE_ID, DAY_ID, FLIGHT_ID)
    VALUES
    (:schmf.ROUTE_ID, :schtm_skmk.day_id, 1);
    COMMIT;
    msg_alert('end insert schtm','I',false);
    END IF;     
    if the checkbox is checked, I assigned value '1' to day_id. Then, I want to insert a row into table SCHTM. But, the insert statement fail. The msg_alert '2' pop up. The msg_alert 'end insert schtm' does not pop up, meaning the insert statement fail. It also fail after I replace the insert statement with the exact value of the item. But if I execute this statement in SQL plus, it insert a row into the database.
    What is strange here is it did work before, I successfully insert 2 rows into database. But when I test it again just a while later, it never work anymore.
    Please help.
    Thanks,
    Shu Wen

    It seems that you have missed ELSE. By the way there is only one INSERT ...

  • Close and save dialog when no changes made

    Hi,
    Mac OS 10.8.2 / CS5.0 / file stored on networked share
    Why amd I getting a save changes dialog when all I have done is open and then close an InDesign document?
    Any ideas appreciated.
    /timothy

    If you change the zoom of the document  then you'll be asked about saving changes.
    I think also that if auto saves have been made that will also trigger the question.
    Does it happen if you open and then close within a few seconds, without changing the zoom or anything at all?

  • Problem with WHEN-CHECKBOX-CHANGED and ON-POPULATE-DETAILS

    I have a detail block with a relationship set up to a second block. In my first block, if I cause an error but the next action I take is to press a checkbox on another record, my error will display and the raise form trigger failure is triggered but the checkbox changes it's value and the cursor is displayed on the record with the error. I didn't want the checkbox to change if an error occurred. I tracked this through the trace and saw the on-populate-details is fired between the error and the when-checkbox-changed trigger. I went through debug and saw because of the erorr, the system will do a 'return' back to the sending action. I beleive this return is causing the when-checkbox-changed to fire. I'm just guessing here. I tried a similar action on another form without a relationship set up. That would eliminate the on-populate-details trigger. When I did a similar error, I got exactly what I was looking for. I caused the error but pressed the checkbox on another record. The error displayed but the checkbox did not change and the cursor returned to the error record. I need the record to have this relationship. Consequently, I need the on-populate-details trigger. Can anyone think of a solution? I'm currently on Forms 6I. We are going to forms 10G in the next few months. But I really need a solution on my current set up. Thanks.

    The getNextDatabankRecord() call is at the beginning of my run code. I use one step just for this line code.
    Code :
    public void run() throws Exception {
              beginStep("CHARGEMENT DES DONNEES SUIVANTES");
                   info("Chargement des prochaines données...");
                   getDatabank("NouvellesIA").getNextDatabankRecord();
              endStep();
    Stop the user after this step and goto the finish section should not be a problem...
    If I use the "When out of records" option, does it jump directly to the finish section ?
    Thanks,
    Benoit.

Maybe you are looking for

  • Problem in moving to final interanl table

    Hi all,   i have one problem when moving all the fileds in final internal table t_eina is the final internal table i want to itab-matnr and maktx in t_eina or anyother final internal please correct the code according to htis requriment.if any one is

  • Has this happened to anyone else? if so how did you fix it?

    my computer doesn't start up right. I start it, goes to startup screen and then either stays there or a black screen pops up and says "job reset will occur after ## more consecutive failures" and then it stops doing everything.

  • Using XMLEncoder in Applet causes securityexception

    I've written a simple Applet which should be able to XMLEncode a bean and write the XML-code to the standard output. (later it should be expanded to place various beans on a panel and write the XML to the server the applet is placed on, to be able to

  • Connect one BW system to Multiple Portals

    Hi, My current client owns 2 companies and they both have their own portal, the issue is that they would like to implement same report for both companies to use, which means we will have to use same queries on 2 different portals. i.e  Assuming compa

  • Finder: Zoom slider is not working

    Hi Friends. If I open a new finder window, the zoom slider is working in the symbol view. But if I change to the column view (Apple-3) and back to symbol view, I can slide the zoom slider how I want, the zoom is not working. Unfortunately it happens