How to programmatically set the value to current Page layout property?

Hi,
How do I set any text value to the current page layout [comment] property and save it.....here my current page is using a custom page layout called spPageLayout1
To be very much generalized how I can set and save any value to current page property programmatically....on load event I need to set the value.
It is a publishing page layout.

Hi,
According to your post, my understanding is that you want to set the value to current Page layout property.
To get current page property, you can refer to:
How to get current Pages details in SharePoint2010 publishing site
Get Content Field Value in Article Page
To get current page layout property, you can refer to:
PublishingPage.Layout Property (Microsoft.SharePoint.Publishing)
PageLayout.Title Property (Microsoft.SharePoint.Publishing)
Best Regards,
Linda Li
Linda Li
TechNet Community Support

Similar Messages

  • How to programmatically set item value

    I created button ‘Accept ALL’ within region to set all values of field to ‘Y’ when clicked on and another button ‘Reject ALL’ to set all field values to ‘N’. Values are intialy derived from
    Region Source (partial query only):
    ...DECODE(eval_contract_accepted_ind,'Y',htmldb_item.text(6,'YES',3,3),'N',htmldb_item.text(6,'NO',3,3),NULL,htmldb_item.select_list(6,'Y','Yes;Y,No;N')) accepted,...
    So values in that field are populated conditionally from static lov Yes;Y,No:N
    I created two processes and allocated them to the relevant button, but non of the values get set.
    ACCEPT_ALL process:
    for i in 1..htmldb_application.g_f01.count
    loop
    if htmldb_application.g_f06(i) not in ('YES','NO') then
    htmldb_application.g_f06(i) := 'Y';
    end if;
    end loop;
    REJECT_ALL process:
    for i in 1..htmldb_application.g_f01.count
    loop
    if htmldb_application.g_f06(i) not in ('YES','NO') then
    htmldb_application.g_f06(i) := 'N';
    end if;
    end loop;

    Hi,
    According to your post, my understanding is that you want to set the value to current Page layout property.
    To get current page property, you can refer to:
    How to get current Pages details in SharePoint2010 publishing site
    Get Content Field Value in Article Page
    To get current page layout property, you can refer to:
    PublishingPage.Layout Property (Microsoft.SharePoint.Publishing)
    PageLayout.Title Property (Microsoft.SharePoint.Publishing)
    Best Regards,
    Linda Li
    Linda Li
    TechNet Community Support

  • How can I set the value to a session bean from backing bean

    Hi Experts,
    How can I set the value to a session bean from backing bean where I have created getter and setter
    methods for that variable.
    Basically I am using ADFUtils class where I am able to get the value from session bean
    using following expression
    String claimType =
    (String)ADFUtil.invokeEL("#{ClaimValueObj.getClaimType}");
    Thanks
    Gayaz

    Gayaz,
    Wrong Post !!
    Post in JDeveloper and ADF
    Thanks
    --Anil                                                                                                                                                                                                                               

  • How I can set the spelling language in Pages for iPad?

    how I can set the spelling language in Pages for iPad? may for german...

    how I can set the spelling check to other language in Papers/iPad?
    The only choices you have in the iPad itself are to change the keyboard or change the user interface language. If that doesn't do what you want, probably best ask the people who make Papers.

  • How do you set the value of an enumeratio​n programati​cally

    I would like to be able to select (programatically) the value of an enumeration.  I don't seem to be able to find any reference to how to do that.
    Thanks.
    Solved!
    Go to Solution.

    True, True.  The original post wanted to know how to programmatically "select" the enum value.  To me, that means to either force the enum to display another value, or retrieve the current value.   I thought Ben was referring to the fact that you can't programmatically set or initiate new values into an enum.  Which as he said, can only be done with a Ring.
    "In your example you're not "getting" the value of the enum. You're converting it to a string. That's a different operation."
    I showed two ways to get the value,  one gets the current string value associated with the numeric value, and the other gets the current numeric value.  i went further in the attached vi, by demonstrating how to change the current (displayed) value of the enum by using a string.  (IFF you already know the string values in the enum.)   
    In my program, i use a typedef cluster with an enum in it.  At runtime, i need to "select" the active enum value based on which operation i'm performing.  I know from elsewhere in the program what operation i need, but it's string, and there's no easy way to change the value of an enum with a string, except with the backdoor methods i showed.  
    I wish my cohort woulda used a ring.  ;-)

  • How to programmatically set the real-time CVI startup DLL?

    Dear NI Support Engineer:
    I'm part of a team of software engineers working on a real-time aerospace app at Honeywell (Coon Rapids, MN campus).  We're using LabWindows/CVI 9.0 and three LabView 8.6 real-time modules.
    Up until now, we've been using the CVI debugger to launch our real-time apps or just copying the app DLL to C:\ni-rt\cvi on the real-time box and setting it as the default startup DLL.
    What we need to do now is create our own directory structure at the root of C: on the real-time box (which, by the way, is using the Reliant file system).
    In fact, we have created directory ug7500 at the root of C: on the realtime box, and two subdirectories (one for data and one for results) directly under directory ug7500.  We'd like to place all of our app DLLs in the ug7500 directory and have the ability to change the default startup DLL programmatically.
    We've been using your LabWindows/CVI Real-time File Copy Utility to set the startup DLL whenever we're not using the debugger.  That was just fine for the first stage of our development.
    At this stage, however, we need be able to set the startup DLL programmatically.  We have not been able to find out how to do this from reading the real-time module documentation.
    Can you either point us at some documentation on programmatically setting the default startup DLL, or e-mail us the instructions, or give us a phone call and explain what steps we must take.
    Thank you very much.
    Vic
    763-957-4168

    Hello All,
    For the reference of anyone else trying to do this, you can modify the INI file to change the startup DLL. Using the INI instrument that ships with CVI (C:\Program Files\National Instruments\CVI90\toolslib\toolbox), you can find the StartupDLLs tag and replace the last value with your startup DLL, such as:
    #include "inifile.h"
    #include <cvirte.h>
    static int status;
    static IniText myINIFile;
    int main (int argc, char *argv[])
     if (InitCVIRTE (0, argv, 0) == 0)
      return -1;    /* out of memory */
     myINIFile = Ini_New (0);
     status = Ini_ReadFromFile (myINIFile, "c:\\ni-rt.ini");
     status = Ini_PutRawString (myINIFile, "LVRT", "StartupDLLs", "c:\\NI-RT\\system\\cvi_lvrt.dll;c:\\ni-rt\\system\\nidevldp.dll;nisysapirpc.dll;niorbp.dll;c:\\ni-rt\\system\\mxsemb.dll;c:\\ni-rt\\system\\nipxism.dll;c:\\NI-RT\\cvi\\myStartup.dll;");
     status = Ini_WriteToFile (myINIFile, "c:\\ni-rt.ini");
     return 0;
    Right now, there are some caveates with using CVI 9.0 to manipulate an INI file to be used on an RT target. The INI functions currently add line breaks automatically for large tag values and adds quotes around the values. For many INI files this is ok (such as TestStand INI files), but it will not work on an RT target. To remove these features, modify the following lines of the inifile.c file located in the same directory as the INI instrument:
    1. On line 38, change the default value of INI_NUM_CHARS_PER_LINE from 80 to a large number such as 8000.
    2. Comment out line 953 (newEntry->addMarkerQuotes = addMarkerQuotes;
    Now you should be able to programmatically change the INI file of your target machine and, therefore, change the startup DLLs.

  • How do I set the value of a dynamic row text field

    I have a repeated row form which contains a button and multiple text fields.  There is a text field (Input Data Field) further up with some information I want to place in the table and multiple buttons that I want to read the value of and set to the table.  I apologize there are multiple questions I have and I am using pseudocode to describe it.
    Top form looks like
    InputField
    | ButtonX1 | ButtonY1 | DescriptionX1 (read only Text Field)
    | ButtonXn | ButtonY1 | DescriptionXn
    OutputRow looks like
    | ButtonOutput | OutputField1 | OutputField2 | OutputField3 |
    So I would like it to do
    ButtonX1.click
    OutputTable.OutputRow.addInstance(true)  //this works - everything else I have questions on
    OutputTable.OutputRow.OutputField1.rawValue = DescriptionX1.rawValue
    Question 1
    How do I address the location in each table to set a value
    Question 2
    How do I get the value of the description field in the same table and row as the button
    I would like to say something to the effect of  OutputTable.OutputRow[??].OutputField1.rawValue = this.parent.DescriptionX
    OutputTable.OutputRow.OutputField2 = InputField.rawValue
      Same question as above - how do I specify a dynamic row - is this the proper syntax for getting the value from the input field?
    OutputTable.OutputRow.OutputField3 = this.ButtonLabel
    Question 3
      How can I get the value of the button's label to set in the field
      There should be very many of these buttons and buttons will be added - I would prefer to set the value based on the button's label to make the value easier - not requiring changing the code
    Question 4 - unrelated to those above.
    Is it possible to build the first table
    | ButtonX | ButtonY | Description |
    from an XML File.  I have seen examples of how to build if it is just data, but can the XML be pushed into a form with code to do the above actions?

    Each object in a form must have a unique name. I doing so it is not neccessarily the name but the path or SomExpression associated with that object that must be unique. In your case you have a Table.Row.object configuration. The Row is the part that is repeating so to give each object a unique name an instance number is placed on the repeating part. So objects in the 1st row woudl be Table.Row[0].object...objects in the second row woudl be Table.Row[1].object etc .....You can see this by adding a debug instruction on the Enter event of the description field. Put the code app.alert(this.somExpression) and when you enter the field you will see what the somExpression is. Do this for a few rows and you will see the pattern (don't forget to remove the debug code from the enter event). Now you know what you have to use to address the fields. If no instance is given it is assumed to be 0 ..that is why only the 1st row is being affected.
    So now to answer your questions:
    Question1: The square bracket notation is an issue for javascript (this is the notation for an array) so we have to use a different means of addressing the field to include the instance number. So to address the Description in the 3rd row we woudl use:
    xfa.resolveNode("Table.Row[2].Description").rawValue = "This is my new description";
    Note that the instance number is 2 for the 3rd row because the instance numbers are 0 based.
    Question2. The resolveNode notation allows you to pass a string so you can also concatinate expressions to make the string. If you are writing code on a button in the same row you can get the instance that you are on by using the expression this.parent.index. The "this" portion refers to the current object (the button) and the parent.index gets you th eindex of the Buttons parent. If the button is embedded deeper in a hierarchy then you can continue to add parent indicators until you get back to the node that you want. So rewriting your expression from Q1 it woudl be:
    xfa.resolveNode("Table.Row[" + this.parent.index + "].Description").rawValue = "This is my new description";
    Question3: The buttons caption can be retrieved by using ButtonName.caption.value.text.value
    Question4: When you say build from an XML file. What are you expecting to come from the XML file? The caption that goes on the button? Typically the XML file carries data (not to say that it cannot carry other things). Just need a bit of clarification on this one first.
    Hope that helps
    Paul

  • How to Programmatically Set the limit (max, min input) of a control inside a cluster?

    I want to programmatically set the limit (max, min input) of a control inside a cluster. (see attached VI).
    The max, min value will be read from a file. The input of the control must be within the range defined by the max and min value.
    Can anyone tell me how to do it?
    Thanks a lot for your kind help.
    Xiaogang

    Accessing the properties of a cluster (or array) is not a trivial operation until you have done it once. It's a two step (at least) process : first, ask for a reference (array of...) to the objects contained in the cluster, then tell LV what kind of object you are adressing.
    See the attachment.
    Chilly Charly    (aka CC)
             E-List Master - Kudos glutton - Press the yellow button on the left...        
    Attachments:
    How to set limit[1].vi ‏52 KB

  • How to programmatically set the Visibility of an Iview INVISIBLE ?

    Hi ..... I need to programmatically set the visibility of an IView for a user Invisible - In order to achieve that , I am trying the below code....But getting errors-
    Code -
    Hashtable env = new Hashtable();
    env.put(Context.INITIAL_CONTEXT_FACTORY,"com.sapportals.portal.pcd.gl.PcdInitialContextFactory");
                 env.put("com.sap.portal.jndi.requested_aspect","com.sap.portal.pcd.gl.PersistencyAspect");
    env.put("java.naming.factory.object", "__IPcdContext__");
    InitialContext iCtx = null;
    String iViewID = "pcd:portal_content/ABC/1Portal/mywork/iviews/XYA_iViews/adf.ivw_ess_jspdynpage";
                 iCtx = new InitialContext(env);
                 IiView result =(IiView)iCtx.lookup(iViewID);     
                 IiViews iViewSrv = (IiViews)PortalRuntime.getRuntimeResources().getService(IiViews.KEY);
    INewObjectDescriptor IVtoCreate =(INewObjectDescriptor) iViewSrv.instantiateDescriptor(CreateMethod.NEW,"par:/applications/com.sap.km.cm/components/navigation",request.getUser());
    IVtoCreate.putAttribute("com.sap.portal.navigation.invisible", true);
    the above method putAttribute is not apllicablt for (String,Boolean)\
    Please suggest as to how can I programmatically set an Iview Visible/Invisible .

    I think the property is com.sap.portal.navigation.Invisible with a capital I for invisible...
    This blog has an example: Hiding portal role content with a simple iView

  • How can i set the values to text box by selecting from drop down list.

    hi ,
    i am using struts and jsps. i have a dropdown list of names(getting the values of names from database), i want to get address and phone number of that selected one.how can i get that?

    Hi swarupa,
    Well My advice in this senario wud Be
    Either U can make Use of XmlHttp Object through javascript(AJAX way).
    Or U need to Maintain the State of the entire form and then refresh the page to get those results....
    just for U r reference i am attaching a link which was programmed using ASP @ server side and which made use of XmlHttp Object.....
    http://www.w3schools.com/ajax/ajax_database.asp
    Just try to simulate the samething in your own way....
    REGARDS,
    RAHUL

  • How do I set the grammar properties in Pages?

    I would like to change the setting on what grammar the Apple Pages proofreader checks. How can do change the settings in the proofreader?
    The two biggest annoyances in Pages proofreader is "Complex Word Choice" and "Wordy Expression". Depending on what is being written, there is sometimes a need for using "complex word choices" or "wordy expressions." For instance, I recently wrote "proceeded" and Pages marked it as a "complex word choice." It suggested that I use "continued" instead. First, I do not see "proceeded" as a complex word. Any sixth grader should understand the word "proceeded." Second, varying word choice makes a document more readable in my opinion. Since I used "continued" in a previous statement, I prefer not to use it so soon again. When I provide a direct quote from a source, which I often have to do, I get a lot of "Wordy Expression" marks from pages. Being a direct quote, I can't change what was said.
    I do not want to turn the grammar checker off, but I would like to disable these two specific checks within the proofreader.
    Thanks.
    James

    I agree that your choices are superior to the programmed suggestions.
    Since I am grateful for the education that I received, and have yet to meet a computer that can write, I never, ever use the grammar checker.
    A crutch for life only helps you limp better.
    Peter

  • How do I set the document language in Pages '13?

    In Pages '09 it was possible to set a document's language by going to the More tab in the Text menu of the Inspector and selecting the language from the pull-down menu.
    In Pages '13 this has disappeared from the text format More sidebar, and I cannot find any way to set the language at all. It is possible to alter the spell-checking language in the Spelling and Grammar menu (under Edit in the menu bar), but this also indicates that the document language is set somewhere centrally. See this screenshot, where I have a document that was obviously set to Br. English and I want it in Am. English:
    I have to work in multiple languages and various flavors (it's the same in German). My system language is set to English and my keyboard to Am. English.
    Any idea of what to do?
    Thanks,
    Pato

    Patito wrote:
    It is possible to alter the spell-checking language in the Spelling and Grammar menu (under Edit in the menu bar)
    That is all you can do at present with Pages 5.  Like Peter said, if you want something more, you need to go back to Pages 4.

  • How do I set the starting or opening page?

    When a user first opens an ibook, is there a way to set which page it initially opens to?
    (I'm creating a book that opens right to left and I'd love the reader to start on the last page.)
    Thanks for any help or suggestions!

          Is this your experience?
    I think what is displayed (first page/first chapter) on the first use depends on the template and orientation. In any case, the flow is still right to left....first to last.
         What if the last page was labeled page #1?
    Is this the same question? If so, same reply as before.
    If you want stylistic control over your content in a non-standard IBA way, you may want to consider making an app where such fluid navigation can be applied.

  • How to set the value of MaxRow Property of DB Adapter 11g dynamically

    I have the following requirement:-
    i am using DB Adapter to connect with MsSQL server for fetching the records from the table by using simple Select Query in my DB adapter.
    1. Receive request from Web Service Client number of records as input to fetch records form MsSQL Server.
    2. Return the result set to the service consumer
    So, here i m using MaxRow Property of Database Adapter for the number of records to be returned. But the problem is that how i can set the value to the MaxRow Property of DB Adapter dynamically from the value received as input.
    If you have any other idea to return the records dynamically from MsSQL server .Please help me.

    If you are using the DB Adapter as a reference and as you said, you are using custom SQL i guess...
    you can use the sql like...
    select top 1 * from tablename, this will result only 1 row from database(top record)...
    or select top 5 percent * from tablename, if the rows in the database are 100, then it will return the top 5 records in the database...
    check the exact syntax of top command with sql server...but using top keyword should solve your purpose to limit the number of records....
    Hope this helps...
    Thanks,
    N

  • Setting the value of a java variable in javascript function

    How can i set the value of a java variable in a javascript function?
    <%
    String fName = "";
    %>
    now i want to define a javascript function which can set the value of fName to the value it has been passed.
    <script language="javascript">
    function setJValue(val)
    </script>
    Thanks

    The only way you could simulate this, would be call the same page inside the Javascript function, and send it the parameter that was passed. Then you would have your Java code retrieve this parameter by request.getParameter("value");, and set the variable accordingly.

Maybe you are looking for