Disabling and or hiding parameter controls depending on the value of a popup

How should I go about doing this? I've set the flags for the popup param to PF_ParamFlag_SUPERVISE like so
def.flags = PF_ParamFlag_SUPERVISE;
PF_ADD_POPUP(
     "Mode",
   6,
   1,
     "Option 1|Option 2|...",
   POPUP_MODE_ID
And I'm capturing the PF_Cmd_USER_CHANGED_PARAM command like so
case PF_Cmd_USER_CHANGED_PARAM:
     ERR(UserChangedParam(in_data, out_data, params, output, reinterpret_cast<PF_UserChangedParamExtra *>(extra));
     break;
static PF_Err UserChangedParam(
    PF_InData* in_data,
    PF_OutData* out_data,
    PF_ParamDef* params[],
    PF_LayerDef* outputP,
    PF_UserChangedParamExtra* extra)
    PF_Err err = PF_Err_NONE;
    if (extra->param_index == POPUP_MODE_ID)
        if (params[POPUP_MODE_ID]->u.cd.value == 2)
             //Code to enable and show the controls
        else
             //Cose to disable or hide the controls
    return err;
Am I doing everything right so far? What code do I need to put in the "if (params[POPUP_MODE_ID]->u.cd.value == 2)" block to disable a parameter? How different would the code be to hide the parameter completely? Can I hid entire topics like I can hide parameters? I'd have a use for all three things, I just can't figure out how to do them.

I took a look at the Supervisor sample project. I've managed to figure out how to disable controls, which I've done like so:
AEGP_SuiteHandler suites(in_data->pica_basicP);
params[CONTROL_ID]->ui_flags |= PF_PUI_DISABLED;
params[CONTROL_ID]->flags |= PF_ParamFlag_COLLAPSE_TWIRLY;
ERR(suites.ParamUtilsSuite3()->PF_UpdateParamUI(
    in_data->effect_ref,
    CONTROL_ID,
    params[CONTROL_ID]
Enabling should be something this instead:
params[CONTROL_ID]->ui_flags &= ~PF_PUI_DISABLED;
What I can't figure out, still, is how to hide a control. I've tried to set the PF_PUI_INVISIBLE flag but that did not seem to change anything. It looks like the Supervisor plugin is setting the exact same flag to hide controls but it must have something else that I'm missing.

Similar Messages

  • Disabling button depending on the Value of a field in a standard page

    Hi,
    How can I disable a button depending on the value selected in a particular field of the same page? Is it possible to do so in a Oracle standard page? Please guide me in resolving this requirement.
    Thanks,
    Swagatika

    Swagatika,
    You can attach PPR event to the textinput field and use method
    pageContext.ForwardImmediatelyToCurrentPage().As process request method will be called again,here you can use method setDisabled(boolean) in OAsubmitButtonBean, to enable or disable your button!
    --Mukul                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • How to fill up the Flex ProgressBar control ,depending upon the Controls Seelcted inside the MXML

    Hi ,
    Please , let me know  How to fill up the Flex ProgressBar control ,depending upon the Controls Seelcted inside the MXML 
    Lets say I have five text boxes and a dropdown box in my flex application, how can I make the progress bar fill up when there is text in each box, and the dropdown selected. 
    Please help
    Thanks in advance .

    Hi Kiran,
    You can do something like below to implement the functionlaity you needed...
    <?xml version="1.0" encoding="utf-8"?>
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical" verticalAlign="top"
        horizontalAlign="center" backgroundGradientColors="[0x000000,0x323232]" paddingTop="0" viewSourceURL="srcview/index.html">
        <mx:Script>
            <![CDATA[
              private var j:uint=0;
              // Event handler function to set the value of the
              // ProgressBar control.
              private function runit():void
                  if(j<=100)
                    j+=10;
                     bar.setProgress(j,100);
                     bar.label= "CurrentProgress" + " " + j + "%";
                  if(j>100)
                     j=0;
                     check1.selected=false;
                     bar.setProgress(j,100);
                     bar.label= "CurrentProgress" + " " + j + "%";
              private function checkFunction():void
               if(!check1.selected)
                 if(j<=100)
                    j-=10;
                     bar.setProgress(j,100);
                     bar.label= "CurrentProgress" + " " + j + "%";                
                  if(j>100)
                     j=0;
                     check1.selected=false;
                     bar.setProgress(j,100);
                     bar.label= "CurrentProgress" + " " + j + "%";
                else
               runit();
            ]]>   
        </mx:Script>
        <mx:Panel title="ProgressBar Control" layout="vertical" color="0xffffff" borderAlpha="0.15"
             paddingTop="10" paddingRight="10" paddingBottom="10" paddingLeft="10" horizontalAlign="center">
             <mx:Label width="100%" color="0x323232"
                text="Click the button to increment the progress bar." />
                <mx:HBox>
              <mx:CheckBox id="check1" label="Check Me" color="#123456" click="checkFunction();"/> 
            <mx:Button id="Speed" label="Click" click="runit();" color="0x323232"/>
              </mx:HBox>
            <mx:ProgressBar id="bar" labelPlacement="bottom" themeColor="#EE1122" minimum="0" visible="true" maximum="100"
                 color="0x323232"    label="CurrentProgress 0%" direction="right" mode="manual" width="100%"/>
        </mx:Panel>
    </mx:Application>
    If this post answers your question or helps, please kindly mark it as such.
    Thanks,
    Bhasker Chari

  • I bought a second apple tv and would like to control it with the remote app but cannot find a way to add a second device.  Anyone have an idea how to do that?

    I bought a second apple tv and would like to control it with the remote app but cannot find a way to add a second device.  Anyone have an idea how to do that?

    I'm having the same issue and would like to get some help.  I set up a second Apple TV in our bedroom and wanted to be able to control it using my iPhone like I do with the Apple TV in the living room.  The new Apple TV is active on the network and I've made sure the same Apple ID is used for both the Apple TV as well as the Remote App on my iPhone.  I'm just wondering what I might be overlooking.

  • My ipod touch gen 5 is disabled and wont sync, i tried to reinstall the itunes (yes, the latest version) but still itunes doesnt recognized my device. help :(

    My ipod touch gen 5 is disabled and wont sync, i tried to reinstall the itunes (yes, the latest version) but still itunes doesnt recognized my device. help

    Did you place the iPod in recovery mode? That is required for a disabled iPod
    Disabled
    Place the iOS device in Recovery Mode and then connect to your computer and restore via iTunes. The iPod will be erased.
    iOS: Wrong passcode results in red disabled screen                         
    If recovery mode does not work try DFU mode.                        
    How to put iPod touch / iPhone into DFU mode « Karthik's scribblings        
    For how to restore:
    iTunes: Restoring iOS software
    To restore from backup see:
    iOS: How to back up     
    If you restore from iCloud backup the apps will be automatically downloaded. If you restore from iTunes backup the apps and music have to be in the iTunes library since synced media like apps and music are not included in the backup of the iOS device that iTunes makes.
    You can redownload most iTunes purchases by:
    Downloading past purchases from the App Store, iBookstore, and iTunes Store        

  • Using int pointer as parameter in dll, but the value of parameter doesnot change

    Hello, I have a function in dll as void set(int * a){ (*a)=99;}
    And I connect a int32 to the dll. But when I run the vi, the value of int32 does not change. 
    As the pic shown below:
    Solved!
    Go to Solution.
    Attachments:
    a.png ‏45 KB

    You connected a control to the DLL parameter. That means the value from the control is passed to the DLL, ... and finito! You need to connect an indicator to the right side of the DLL parameter to see the value returned from the DLL.
    Rolf Kalbermatter
    CIT Engineering Netherlands
    a division of Test & Measurement Solutions

  • Parameter List displaying all the values on Parameter form

    Dear All...If I uncheck the "Restrict List to predetermined values" option, then report parameter form displays all the values on web parameter form instead of displaying those values in the List Item. Is it the Default behaviour of Oracle Reports 10g or Can I control it anyway because if I've 1000 entries in a list, then displaying all those values openly on the form is an ugly thing and it increases the size of parameter form very much.

    Hello,
    A solution is provided in the Note :
    Note.465886.1 How to Implement an Alternate Solution to Unrestricted List Of Values (LOV) in Parameter Form on the Web:
    regards

  • ColumnChart color depending on the value of the column

    Hi,
    I'va been trying for 2 days to change the colors of columnseries in a columnchart and it is actually awful. I've tried to do it inline without custom itemRenderer but I quickly understood that it is impossible. I then looked on the internet, and found that it was maybe possible by creating a custom itemRenderer class, extending ProgrammticSkin and implementing IdataRenderer.
    I have tried but am not at all able to retrieve the value of the column inside the itemRenderer. Even more, the so called _chartItem is always null and never never carries anything from anyparent.
    I'm a bit exhausted of trying and getting this value, so if you have some idea, i'll be very grateful.
    Here is the code for my itemRenderer class:
    import flash.display.Graphics;
        import flash.geom.Rectangle;
        import mx.charts.ChartItem;
        import mx.charts.chartClasses.GraphicsUtilities;
        import mx.charts.series.items.ColumnSeriesItem;
        import mx.controls.Alert;
        import mx.core.IDataRenderer;
        import mx.graphics.IFill;
        import mx.graphics.IStroke;
        import mx.skins.ProgrammaticSkin;
        public class ColorRenderer extends ProgrammaticSkin implements IDataRenderer
            public function ColorRenderer():void
                super();
            private var _chartItem:ChartItem;
            public function get data():Object
                return _chartItem;
            public function set data(value:Object):void {
                _chartItem = value as ColumnSeriesItem;
                invalidateDisplayList();
            private static const fills:Array = [0xFF0000,0x00FF00,0x0000FF,
                0x00FFFF,0xFF00FF,0xFFFF00,
                0xAAFFAA,0xFFAAAA,0xAAAAFF];
            override protected function
                updateDisplayList(unscaledWidth:Number,unscaledHeight:Number):void {
                super.updateDisplayList(unscaledWidth, unscaledHeight);
                var g:Graphics = graphics;
                g.clear(); 
                g.beginFill(fills[(_chartItem == null)? 0:_chartItem.element.y]);
                Alert.show(_chartItem.index.toString());
                g.drawRect(0, 0, unscaledWidth, unscaledHeight);
                g.endFill();
        } // Close class.
    } // Close package.
    Thank you

    It worked, thanks
    Date: Wed, 21 Apr 2010 09:03:14 -0600
    From: [email protected]
    To: [email protected]
    Subject: Flex ColumnChart color depending on the value of the column
    Have you looked at doing per-item fills?
    http://help.adobe.com/en_US/Flex/4.0/UsingSDK/WS2db454920e96a9e51e63e3d11c0bf69084-7c3f.ht ml
    This feature lets you define a function that customizes chart item fills based on their values.
    >

  • Variant network depending on the value of the characteristics.

    Hi,
    I want to create a project from a sales order for a configurable material. The problem is that the network should be slightly different depending on the value of the characteristics used in the configurable material. For example, it could happen that one operation should not be executed, or that this operation should take longer because of the characteristics.
    How should I proceed?
    Thanks in advance.
    Regards,
    Luis.

    Thanks for your answers, but I needed a more specific answer. Anyway, in the end I found the solution:
    - I had to create a configuration profile for the standard network (CU41), and then I had to assign the same class as the one assigned to the configuration profile of the configurable material.
    - Then, I run t-code CN02, and I had to select one operation and then I clicked "Extras --> Object Dependencies --> Editor". And finally, I just chose the dependency type and filled it with its corresponding code.
    Still, I have a problem:
    - Is it possible to set the value of the Normal Duration (or any other parameter of the operation) depending on the value of one characteristic?
    For example: The value of my characteristic A is 2, so I want to set Normal Duration = 10*(Value_of_A) = 20 for the first operation of the standard network. Is it possible in standard SAP???
    Thanks!

  • Shading part of a JTable Cell dependent upon the value of the cell

    Hi
    Was hoping some one woudl be able to provide some help with this. I'm trying to create a renderer that will "shade" part of a JTable cell's background depending upon the value in the cell as a percentage (E.g. if the cell contains 0.25 then a quarter of the cell background will be shaded)
    What I've got so far is a renderer which will draw a rectangle whose width is the relevant percentage of the cell's width. (i.e. the width of the column) based on something similar I found in the forum but the part I'm struggling with is getting it to draw this rectangle in any cell other than the first cell. I've tried using .getCellRect(...) to get the x and y position of the cell to draw the rectangle but I still can't make it work.
    The code for my renderer as it stands is:
    import java.awt.Component;
    import java.awt.Graphics;
    import java.awt.Graphics2D;
    import javax.swing.JLabel;
    import javax.swing.JTable;
    import javax.swing.table.TableCellRenderer;
    public class PercentageRepresentationRenderer extends JLabel implements TableCellRenderer{
         double percentageValue;
         double rectWidth;
         double rectHeight;
         JTable table;
         int row;
         int column;
         int x;
         int y;
         public Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected, boolean hasFocus, int row, int column) {
              if (value instanceof Number)
                   this.table = table;
                   this.row = row;
                   this.column = column;
                   Number numValue = (Number)value;
                   percentageValue = numValue.doubleValue();
                   rectHeight = table.getRowHeight(row);
                   rectWidth = percentageValue * table.getColumnModel().getColumn(column).getWidth();
              return this;
         public void paintComponent(Graphics g) {
            x = table.getCellRect(row, column, false).x;
            y = table.getCellRect(row, column, false).y;
              setOpaque(false);
            Graphics2D g2d = (Graphics2D)g;
            g2d.fillRect(x,y, new Double(rectWidth).intValue(), new Double(rectHeight).intValue());
            super.paintComponent(g);
    }and the following code produces a runnable example:
    import javax.swing.JFrame;
    import javax.swing.JScrollPane;
    import javax.swing.JTable;
    import javax.swing.table.DefaultTableModel;
    public class PercentageTestTable extends JFrame {
         public PercentageTestTable()
              Object[] columnNames = new Object[]{"A","B"};
              Object[][] tableData = new Object[][]{{0.25,0.5},{0.75,1.0}};
              DefaultTableModel testModel = new DefaultTableModel(tableData,columnNames);
              JTable test = new JTable(testModel);
              test.setDefaultRenderer(Object.class, new PercentageRepresentationRenderer());
              JScrollPane scroll = new JScrollPane();
              scroll.getViewport().add(test);
              add(scroll);
         public static void main(String[] args)
              PercentageTestTable testTable = new PercentageTestTable();
              testTable.pack();
              testTable.setVisible(true);
              testTable.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    }If anyone could help or point me in the right direction, I'd appreciate it.
    Ruanae

    This is an example I published some while ago -
    import java.awt.*;
    import javax.swing.*;
    import javax.swing.table.*;
    public class Fred120 extends JPanel
        static final Object[][] tableData =
            {1, new Double(10.0)},
            {2, new Double(20.0)},
            {3, new Double(50.0)},
            {4, new Double(10.0)},
            {5, new Double(95.0)},
            {6, new Double(60.0)},
        static final Object[] headers =
            "One",
            "Two",
        public Fred120() throws Exception
            super(new BorderLayout());
            final DefaultTableModel model = new DefaultTableModel(tableData, headers);
            final JTable table = new JTable(model);
            table.getColumnModel().getColumn(1).setCellRenderer( new LocalCellRenderer(120.0));
            add(table);
            add(table.getTableHeader(), BorderLayout.NORTH);
        public class LocalCellRenderer extends DefaultTableCellRenderer
            private double v = 0.0;
            private double maxV;
            private final JPanel renderer = new JPanel(new GridLayout(1,0))
                public void paintComponent(Graphics g)
                    super.paintComponent(g);
                    g.setColor(Color.CYAN);
                    int w = (int)(getWidth() * v / maxV + 0.5);
                    int h = getHeight();
                    g.fillRect(0, 0, w, h);
                    g.drawRect(0, 0, w, h);
            private LocalCellRenderer(double maxV)
                this.maxV = maxV;
                renderer.add(this);
                renderer.setOpaque(true);
                renderer.setBackground(Color.YELLOW);
                renderer.setBorder(null);
                setOpaque(false);
                setHorizontalAlignment(JLabel.CENTER);
            public Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected, boolean hasFocus, int row, int col)
                final JLabel label = (JLabel) super.getTableCellRendererComponent(table, value, isSelected, hasFocus, row, col);
                if (value instanceof Double)
                    v = ((Double)value).doubleValue();
                return renderer;
        public static void main(String[] args) throws Exception
            final JFrame frame = new JFrame("Fred120");
            frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
            frame.setContentPane(new Fred120());
            frame.pack();
            frame.setLocationRelativeTo(null);
            frame.setVisible(true);
    }

  • Calculate a measure depending on the value of other dimension

    HI,
    I would like to know if it’s possible to calculate a measure depending on the value of other dimension. I want to calculate this measure in the Business Model and Mapping. I show you how I am trying to do it:
    http://img338.imageshack.us/img338/2496/imagenjp.png
    But when I try to make an aggregation of this measure then I get an error of consistency.
    I think a good example to make you to understand me is the function TODATE which calculates an aggregation depending on one time dimension. I would like to do the same thing but regarding to the value of other dimension.
    Can someone help me? Thanks a lot.

    Hi,
    Do you have that dimension table as a "Sources" in that BMM folder? if yes, then you can use the "Data Type" option and click on "show all logical sources". Then click on your fact table using which you want to do the calculation and then use this formula. After that you can have the aggregation.
    It should work.
    Thanks,
    Rohit

  • Hide Advance table Depending upon the value of dropDown

    Hi,
    I have 2 advance tables. 1st one has a DropDown. Depending upon the value of the dropdown in 1st advance table, the second advanced table should get rendered.
    I tried by getting the value of the dropdown by addingg a PPF and iterating trough the table and I got the value. But when I redirect to the same page, all the selection and other values in 1st advanced table vanish out.
    Can someone help me getting the 2nd table hidden and at the same time retaining the values for the 1st advanced table.
    Thanks in Advance,
    Kaushik Rambhiya

    Kaushik
    Implement PPR for this requirement and dont redirect the page
    Displaying image based selected value of choice bean
    http://oracleanil.blogspot.com/2009/05/ppr.html
    Thanks
    AJ

  • Column displaying as an icon instead of/depending on the value

    Hello,
    I use interactive reports and I've a column (IND_CAMP) that can take 2 values : 0 or 1 (the type of the column is "Number").
    I would like this column displays as an icon, depending on the value (a check box, checked or not).
    Must I change my table or can I do this directly in Apex, for example with the conditional display ?
    Or can I add a column, with a different type, connected to IND_CAMP in my query ?
    thanks for your ideas,
    Fanny

    Hi MDK, thanks for your help,
    I'm sorry but I'm new with Apex and PL/SQL...
    My "checkbox" is in fact only a picture, so I've 2 icons, for example icon1.gif and icon2.gif
    And the value I'm interested in is the value of IND_CAMP (0 or 1).
    Should my query look like this...? :
    SELECT MYTABLE.CDE_CAMP,
    MYTABLE.IND_CAMP
    FROM MYTABLE
    CASE
    IND_CAMP.value WHEN 0
    THEN
    '<img src="#WORKSPACE_IMAGES#icon1.gif" />'
    ELSE
    '<img src="#WORKSPACE_IMAGES#icon2.gif" />'
    ENDI can add a column with the icon and hide the IND_CAMP or I can replace it.
    thanks again,
    Fanny

  • Formula to populate one Person or Group column depending on the value of another Person Group column

    I am looking for a way to popluate the Account information of a Person based on another column where there name in another column.  I have Two Columns   "Name" which is a Person or Group information type and User Account which
    is also a Person or Group Information type.  When an Invidividuals name is entered into the Name column, I what the User Account column to prepolulate.

    Hi,
    For your issue, you can automatically populate User Information depending on the value of another Person or Group column by connectting with User Information List or  connectting with User Profile Web Service:
    http://www.wonderlaura.com/Lists/Posts/Post.aspx?ID=172
    http://blogs.technet.com/b/anneste/archive/2011/11/02/how-to-create-an-infopath-form-to-auto-populate-data-in-sharepoint-2010.aspx
    Best Regards,
    Eric
    TechNet Community Support
    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact
    [email protected]

  • Hello, i recently bought an iPod 5th Generation and it came with a passcode which i did not know of, it is now disabled and i am wondering how to unlock the iPod

    Hello, i recently bought an ipod touch 5th generation and it came with a passcode which i did not know, it is now disabled and i am wondering on how to unlock it using itunes on the computer

    Place the iOS device in Recovery Mode and then connect to your computer and restore via iTunes. The iPod will be erased.
    iOS: Wrong passcode results in red disabled screen                         
    If recovery mode does not work try DFU mode.                        
    How to put iPod touch / iPhone into DFU mode « Karthik's scribblings        
    For how to restore:
    iTunes: Restoring iOS software
    If problem what happens or does not happen and when in the instructions? When you successfully get the iPod in recovery mode and connect to computer iTunes should say it found an iPod in recovery mode.
    However, you will likely run again the Activation Lock
    iCloud: Find My iPhone Activation Lock in iOS 7
    You either have to get the Apple ID and password of the previous owner and enter it or have them remove the iPod from their account.
    Find My iPhone Activation Lock: Removing a device from a previous owner’s account

Maybe you are looking for

  • Not able to deploy BPM Process

    HI, while deploying the bpm process i am getting the error i.e [06:41:46 PM] Error deploying archive sca_ArCnWorkflow_rev1.0.jar to partition "default" on server AdminServer [http://ddrvaka:7001] [06:41:46 PM] HTTP error code returned [500] [06:41:46

  • Loop question in oracle forms

    declare v_comment2 varchar2(2000); Cursor C3 is select a.comment_pad from qc_procedure_results a, qc_procedures b where a.procedure_id = b.procedure_id and drive_id = :qc_daily.drive_id and dept_id = :qc_daily.dept_id and qc_type_id = :qc_daily.qc_ty

  • Thousands of photo duplicates

    Help! I am a new Mac/iPhoto user and am swimming in duplicates of photos, due to indiscriminate dowloading of several backup CDs. Trouble is, I have loaded over 3000 photos into library, and am now stuck because I can't get rid of duplicates without

  • Internal error: 400 Bad request. (117007)

    I get the error in the subject heading every time I try to publish. I read a previous post that said this is caused by not having the email changed in the form. I corrected that, and I'm still getting the error. Any ideas? My client deadline for firs

  • Gray Diamonds

    How can I change the settings such that it does not open a pdf file from within Safari containing a background of small gray diamonds?