Can you programmatically change the iView Title?

Hi,
I have a custom iView, and a requirement is to have the iView tray title changed depending on the content shown.
Is it possible to have the iView Title changed from the custom iView code?

Hi,
Check this code:
Just have these two methods and use the setPCDContextTitle() method
public static void setPCDContextTitle(
        String currentPcdLocation,
        Locale locale,
        IUser user,
        String title)
        throws NamingException, PrivilegedActionException {
        IPcdUtils pcdUtils = PcdAccess.getPcdUtils();
        IPcdAttribute basePcdAttribute =
            pcdUtils.createPcdAttribute(PcdAttributeValueType.TEXT, IAttrPcmGeneral.ATTRIBUTE_TITLE);
        basePcdAttribute.set(locale, title);
        IPcdAttributes basePcdAttributes = pcdUtils.createPcdAttributes();
        basePcdAttributes.put((Attribute) basePcdAttribute);
        PcmAdminBase adminBase =
            (PcmAdminBase) getPCDContext(currentPcdLocation, PcmConstants.ASPECT_ADMINISTRATION, user);
        IPcdContext context = adminBase.getPcdContext();
        context.modifyAttributes("", DirContext.ADD_ATTRIBUTE, basePcdAttributes);
    public static Object getPCDContext(String currentPcdLocation, String aspect, IUser user)
        throws NamingException {
        Context pcdContext;
        Object currentObject = null;
        Hashtable env = new Hashtable();
        env.put(Context.INITIAL_CONTEXT_FACTORY, IPcdContext.PCD_INITIAL_CONTEXT_FACTORY);
        env.put(Context.SECURITY_PRINCIPAL, user);
        env.put(Constants.REQUESTED_ASPECT, aspect);
        try {
            pcdContext = new InitialContext(env);
        } catch (NamingException e) {
            logger.severe(e, "Error in PCDPath");
            throw e;
        try {
            currentObject = pcdContext.lookup(currentPcdLocation);
        } catch (NamingException e) {
            logger.severe(e, "Error in PCDPath");
            throw e;
        return currentObject;
Greetings,
Praveen Gudapati
p.s. Points are always welcome for helpful answers

Similar Messages

  • Can you programmatically change the width of columns in a table control\indicator

    Is it possible to programmatically change the width of columns in a table control\indicator ie to fit to width of the data or in my case the header information.

    Create a property node (or reference) and use the 'Active Cell' property to select which column you want to change and then use the 'Cell size'--> 'Width' property to change the size.
    "There is a God shaped vacuum in the heart of every man which cannot be filled by any created thing, but only by God, the Creator, made known through Jesus." - Blaise Pascal
    Attachments:
    table.vi ‏33 KB

  • Can you programmatically change properties of the Detailed Navigation?

    Is there an SAP EP6.0 API call to allow one to programmatically change the width of the Detailed Navigation, or programmatically hide or unhide it?  I realize that this can be preset, but I am interested in dynamically changing these values.
    Thanks,
    John

    Hi!
    If you look to the sourceCode of your EP (rigthClick->show source) you'll see that some JavaScriptFiles are loaded. One of them is called:
    "WAandNavPanel.js"
    Inside this file are some nice functions like "collapsePanel()" and so on. I didn't try, but perhaps you can use them or they can show you the right way.
    http://<host>:<port>/irj/portalapps/com.sap.portal.layouts.framework/scripts/WAandNavPanel.js
    Regards,
    Christian

  • How can I programmatically change the fill color Settings of the Cwslide ActiveX Controls

    In design mode (Visual Studio 6.0),I want to programmatically change the fill color in properties of  cwslide  ActiveX Controls.what's the command?
    Attachments:
    cwslide.JPG ‏11 KB

    First, if you want to start getting beyond the basics with DAQ, you are going to have to stop using the DAQ assistant and do it with lower level DAQmx VI's.  There are hundreds of examples in the example finder.  You can even right click on the DAQ assistant and select open front panel.  That will create a subVI that you can open and see what is going on behind the scenes.  Do it.  I think you'll find the DAQ task is being recreated on each (though I'm not 100% of how the settings are established or maintained in each section of that subVI).
    The second problem is you have a bit of a race condition on iteration 0.  Those two DAQ property nodes are running at the same time.  So when you read the AI.Max, it may be happening before or after the AI.Max is set in your case structure.
    Third, make sure you wire up your error wires.

  • Can I Programmatically Change the Active Group on a Hypertrend in DSC?

    I would like to know how to programmatically change the active group of a hypertrend in Labview DSC.  I saw a link which said it can be done in Lookout.  But in the DSC module, the active group is read only.
    I know of a hard way to do it.  I could save the hypertrend settings as xmlSettings to a temporary file.  The active group is one of the settings.  I could then change the active group in this text file to point to the new group and then reload the settings.  But this is not a clean way of dong it.
    Anyone know if there is a easy way?
    Solved!
    Go to Solution.

    I found a way to do it but its not very clean.  I dont know why there is not a function to change the current group.
    Here is how I did it.

  • How can you add/change the currency rate in spro?

    Hi all,
    you can add a new currency code by going to spro --- general settings --- check currency codes
    for example: PERU ---> PEN
    But, how can we add/change the currency rate PEN in spro?
    for example: Peruvian Nuevo Sol     = 4,3567619
    Is it still in customizing? And if so, where can i find it?
    Many thanks in advance.
    Kind regards,
    Pamela.

    Hi Aman,
    I have entered the field to add the new currency rate.
    But the system doesn't want to valid my new rate.
    I get the following error message:
    "Input should be in the form ._,____ "
    Do you know how to override that command?
    Thanks.
    Regards,
    Pamela

  • How can you PERMANENTLY change a photo title?

    I know how to change the title of my photos in iPhoto (by clicking on the title of the image or changing it in the information panel). But when I copy the image to another place--for example, dragging it to my desktop or onto a USB stick--the original title, the one with just numbers, appears and the new title is lost. If I change the title on the icon of the desktop image and then re-import it into iPhoto, I get the new title, but there must be an easier way than moving all my photos to my desktop and then moving them back into iPhoto and erasing the original iPhoto photos.

    The trick is not to drag it to the desktop, but instead, use the File -> Export command. In the resulting dialogue set the Kind: to jpeg and then tick the box at 'Title and Keywords' and then complete the export. iPhoto will make a copy of your pic with the title as filename, including any description and keywords you may have added.
    By way of explanation: iPhoto preserves your Original file, no matter what. Changing the filename is a change to the file and would require a modified version. Obviously this would be very expensive in terms of Hard Drive space, so iPhoto does not rename the file. Further, filenames are irrelevant in iPhoto as cameras can produce hundreds of files with the same name. SO iPhoto does not rely on them as an identifier.
    Alternatively, some folks rename their file prior to importing to iPhoto. To do tthis use Image capture (in your Apps folder) to move the pics to a folder on the desktop then use a batch file renaming utility such as Name Mangler to rename the files and then import to iPhoto.
    Regards
    TD

  • How can I programmatically change the colour of tab pages? If not, when?

    I have found that in LabVIEW 6.0.2 the "Dialog" tab control cannot be coloured, but the other type of tab control one can be coloured by the paintbrush tool. I cannot find any property node to programmtically set the colour of the enitre tab control or individual pages. When will these properties be available in LabVIEW?

    The dialog controls and indicators are designed
    specifically for use in dialog boxes. These controls inherit their color from the colors you set in Control Panel >> Display. Because of this you will not be able to programmatically change their color.
    Chris_Mitchell
    Product Development Engineer
    Certified LabVIEW Architect

  • Can I programmatically change the printer paper size from ActionScript?

    Hi,
    I'm a newbie Flash/ActionSript developer and I have been searching for answers for a while with no luck. I wonder if I can get some pointers from this forum.
    I'm trying to programmatically print a movie clip to 8.5" x 11" plain paper regardless of the current paper size setting in the printer. e.g if the user's printer is currently set to use paper size A4, can I change the setting to Letter (8.5" x 11") from ActionScript at runtime? I use PrintJob class for printing the movieclip.
    According to the ActionScript online API spec ( http://www.adobe.com/livedocs/flash/9.0/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context =LiveDocs_Parts&file=00002066.html), I can only READ the paper size setting after the call to PrintJob.start. I can't believe that we are not allowed to change the setting. Maybe I missed something here. Can somebody help me out?
    Thanks in advance!

    check your duplicate thread.
    and, please don't cross-post.

  • How can I programmatically change the voltage range settings in a DAQ Assistant

    Hi,
    First post here.  
    I need to be able to change the voltage range properties of a daqmx DAQ Assistant based on user input.  My hardware, an SCXI-1102C does not allow changing this property on a running task, so I'd like to either set the analog input voltage range before the DAQ Assistant activates, or pause the DAQ Assistant immediately after it starts, set the values and then resume.
    I don't know how to edit the task ahead of time because the DAQ assistant creates the task when it runs, and there is no task before that.
    In the attached picture, I have a conditional section, set to run only if the while loop iteration is 0.  I take the task from the Daq assistant, send it to a stop task vi, set the property, and then send the task on to the start task vi. I can watch it run with the debug light on, and everything seems to work correctly, but on the second (and all the other) iteration of the loop, I read out AI.Max and it seems like the DAQ Assistant has re set it back to 5V.  Can anyone see what is going wrong here?
    BTW, this is continuous acquisition and the code does not produce error messages when it runs.
    I did come across a similar question that someone posted here back in 2006, but his question was specifically aimed at a Labview API (VB, I think), and not an actual G solution.
    Attached are the actual vi in question and a png image of the block diagram.
    Thanks! 
    Ruby K
    Solved!
    Go to Solution.
    Attachments:
    Labview_question.PNG ‏14 KB
    Sample_AIV.vi ‏91 KB

    First, if you want to start getting beyond the basics with DAQ, you are going to have to stop using the DAQ assistant and do it with lower level DAQmx VI's.  There are hundreds of examples in the example finder.  You can even right click on the DAQ assistant and select open front panel.  That will create a subVI that you can open and see what is going on behind the scenes.  Do it.  I think you'll find the DAQ task is being recreated on each (though I'm not 100% of how the settings are established or maintained in each section of that subVI).
    The second problem is you have a bit of a race condition on iteration 0.  Those two DAQ property nodes are running at the same time.  So when you read the AI.Max, it may be happening before or after the AI.Max is set in your case structure.
    Third, make sure you wire up your error wires.

  • Can I programmatically change the FP IAK file in LabView

    We are using our FP-1000 as dataloggers for thermocouples and voltage reading. However the configuration of the setup may change depending on which (and how many) modules are attached to the communication module. I would like my program to go out to the FP and figure out which modules are attached and then ask for channel configuration info form the user. This will prevent from needing multiple iak files and the operator will not have to use FP Explorer. Can this be done? Thanks.

    Mike,
    Yes, this can be done. You can use the low level serial FieldPoint VIs to do what you wish. The FieldPoint Serial VIs are located under the FieldPoint>>Advanced>>Serial Configuration palette. Side Note: These VIs used to be installed by default only if you had LabVIEW RT on the system, you may need to do a custom reinstall of NI-FieldPoint to get the VIs. The VIs allow you to determine what modules are attached (!B), configure the channels (!D), and read/write the channels. These commands are all documented in the FP-1000/1001 Programmers Reference Manual available at http://digital.ni.com/manuals.nsf/websearch/EE241C7357D3F8CE862567840072F554?OpenDocument&node=132100_US .
    Regards,
    Aaron

  • How can you Programmatically recalculate the tax on AR Transaction Line

    Hi
    Does anyone have any clue about the API which can be used to programmatically recalculate the tax on the sales order line.
    We are using EBTAX Engine.
    Regards

    Which tax engine are you using in your environment? Are you using standard Oracle e-biz tax?

  • Can I programmatically change the VI Search Path?

    I'm writing a simple program to periodically mass compile certain directories of my source code.  In my directory structure I try to enforce rules about what is allowed to depend on what, so I want to programatically enforce this during the mass compile.   To do this, I'd need to modify the VI search path before each directory is compiled.  Is there any property or method available for changing the VI Search Path?

    There is, but it's a private property, so it's not documented, and its behavior and/or availability can change with subsequent releases of LabVIEW:
    Message Edited by smercurio_fc on 10-24-2007 05:24 PM
    Attachments:
    Example_BD.png ‏2 KB

  • How can you PERMANENTLY change the default Ken Burns effect?

    I don't like the Ken Burns effect and want to PERMANENTLY remove it from the default setting for slideshows. I know how to deselect it every time I create a new slideshow, but isn't there a way to change the default setting so the Ken Burns effect is not selected unless I want it?

    Terence Devlin wrote:
    You may have a problem with your keyboard as you seem to be unable to type the word 'permanently" in lower case.
    SImilarly, you cannot permanently disable the Ken Burns effect and remove it from the default settings.
    iPhoto menu -> Provide iPhoto Feedback
    Regards
    TD
    I don't know if anyone will ever read this, but I feel compelled to say that:
    a) This reply is great, probably one of the best I've ever seen.
    b) I'm a fan, TD, I'm a fan.

  • How can you increase/change the font size using window.print

    We don't use BI/XML Publisher.
    I have a button with an URL Redirect to print.
    javascript:window.print();
    How can I give the user the option to print with a different font or larger size or optionally to set it the same for everyone?
    thanks
    John

    Hi,
    I would think that, generally speaking, users would print from a Printer Friendly page. This is a page template that has most of the top and bottom (that is, the tabs and footers) of a normal page removed. You can switch a page to a Printer Friendly one fairly easily - see: Re: Print Report without Template for an example. As this is a separate page template, you can use printer-only styling. The downside is that you can only have one Printer Friendly page in your application, so you have to be careful to make any styling generic.
    Andy

Maybe you are looking for