Add predefined text in richhtmlfield control

I have created a custom wiki page layout, in that page-layout i have added a built-in RichHTMLField control.
Now I want to add some text in the control , so that whenever a new page is created , that text would appear in the control(user can later change/delete the text) For Ex:
Header....
Body.....
Footer....
Is this possible?
Please remember to click 'Mark as Answer' on the post that helps you or "Vote As Helpful"

I would hook into ItemAdding/Added event receiver and would add the contents if they are empty.
Other option could be to run some javascript in page layout and add the contents in the pagelayout, if they empty. But this will be virtual, means they will not exists in the page but will only be visible in layout.
Thanks,
Sohel Rana
http://ranaictiu-technicalblog.blogspot.com

Similar Messages

  • How to Add Link Some Text in RichEdit Control in MFC

    I need to add some Text with Link to RichEdit, thats all.
    for example,
    my String is,
    line 1 : PASS
    line 2 :  FAIL
    line 3 : PASS
    line 4 : FAIL
    line 5 : FAIL
    now i want to add this String into RichEdit. and add a Link to Only FAIL text. when i click the FAIL Text(ie, line2,line4,line5) it show some message using Message Box or AfxMessageBox.

    I decided to give it a go and wow it was way harder than I thought it should be.  Here is what I ultimately did. (you can try playing with ITextDocument2, ITextRange2::SetURL, but I didn't get that to work like I wanted.  I finally resorted to
    directly injecting RTF into my RichEdit control.  Here is a brief example (there is a little MFC in here to save time, but the relevant stuff is pure Win32 and the MFC is trivially convertable to Win32).
    m_rich.Create(WS_VISIBLE | WS_CHILD | ES_MULTILINE, CRect(10, 10, 200, 200), this, 1000);
    // TODO: Add extra initialization here
    m_rich.SetWindowText(L"This is a test ");
    m_rich.SetSel(-1, -1);
    m_rich.SetEventMask(ENM_LINK);
    std::string dataStr = R"({\rtf1{\field{\*\fldinst{ HYPERLINK http://example.com }}{\fldrslt{DisplayText}}}}.)";
    std::list<char> dataList(dataStr.begin(), dataStr.end());
    EDITSTREAM es = {
    reinterpret_cast<DWORD_PTR>(&dataList),
    0,
    [](DWORD_PTR dwCookie, LPBYTE pbBuff, LONG cb, LONG *pcb) -> DWORD {
    auto &list = *(reinterpret_cast<std::list<char> *>(dwCookie));
    *pcb = 0;
    while (*pcb < cb && !list.empty()) {
    pbBuff[*pcb] = list.front();
    list.pop_front();
    (*pcb)++;
    return 0;
    auto r = m_rich.SendMessage(EM_STREAMIN, SF_RTF | SFF_SELECTION, reinterpret_cast<LPARAM>(&es));

  • Add New Text - Adobe Acrobat 9.0 Pro

    I have scanned in two documents to my Adobe Acrobat 9.0 Pro and now would like to add some text. When I try to select the TouchUp Text Tool it is "grayed out"; in fact the whole Advanced Editing Tool Bar is "grayed out".
    I can go to the spot where I want to "add text" and hit control and right click and draw a box, but the New Font dialog box does not drop down?
    Can anyone please help or shed some light on what I'm doing wrong?
    Regards, June E. Hudspeth
    Thank you so much.

    I have just re-scanned my document unclicking the "PDA/A Compliant" box and "viola" everything appears to working just "wonderfully"!
    Thank you so much for ending two days of total frustration!
    I also talked with an instructor who taught the Adobe 8 class & he didn't have a clue as to what was wrong.
    Again, I thank you very, very much!
    Regards, June E. Hudspeth

  • How to add custom text on ISA B2B Order

    Hi,
    On Order page of ISA B2B I have created a custom text field  "Shipping Attention".When I try to add this text in the header like
    header.addExtensionData("Z123","Value") in Z_BasketRefreshAction which extends MaintainBasketDispatcherAction, it is not reflecting in the "Shipping Attn"(created in the text tab in CRM)  field in CRM system.
    The flow:
    /b2b/maintainbasket --> Z_BasketRefreshAction --> /b2b/basketrefresh --> MaintainBasketRefreshAction --> b2b/updatedocumentview
    Please let me know if I missing something...
    Thanks in Advance.
    Regards,
    Muthu

    Hello,
    You have covered the first two layers of the request - response cycle cake - the View (JSP) and the Control (Java) layers. The icing is done in the backend BAdI and using the right function module. I am assuming the CRM backend.
    A typical request-response in the application goes like this. I will give example for the header extensions.
    Added the custom variable in the HTML layer (JSP page)
    Traversed through the Dispatcher, Parser and get the input value from the JSP page variable and added it to the Business Object (Header) using addExtensionData.
    The java application layer actually makes an "Update Header" call during the update cycle - like when you click that "Update" button.
    In the SAP E-Commerce design, during this "update" cycles, the application flows through specific BAdI call sequence. It calls what I call the Header BAdI CRM_ISA_BASKET_HEAD when the header information is updated. You have to extend this BAdI and implement at least two methods.
    It has two methods - which are called during this request - response cycle. First method CHANGEHEAD_SET_DATA is called during the request cycle - that is from ISA to CRM (when update is clicked). This is where your extension data has to be transferred from the Java layer to the backend layer (model). You will essentially read from the table IT_EXTENSION and call SAVE_TEXT function module. Since your requirement is to update text, this is the FM to be called. Many other cases use the FM mentioned by Mike. This is where the data from the web layer is persisted in the backend model.
    And the other method GETHEAD_GET_DATA is called during the response cycle. In this method, you will essentially read from the model - in your case READ_TEXT and set it back in the extension layer CT_EXTENSION
    The update header call from the Java layer will now receive the data back from the model and will automagically transfer the values from the backend (ABAP layer) back to the Java layer to be accessible by you in the JSP using getExtensionData call.
    What you have to do are the steps .5 and 6 in order to complete the request-response cycle.
    Easwar Ram
    http://www.parxlns.com

  • How to add standard text in PO and how it is maintained ?

    How to add standard text (paragraph) in PO and how it is maintained ?

    Hi
    Please go through this document.which has a step by step
    Working with Frequently Used Texts
    Use
    You can copy texts from various sources to create PO texts:
    Standard texts
    Certain standard texts are supplied with the system and can be assigned to a purchasing document in Customizing.
    The content of some standard texts is predefined by your system administrator.
    You can also create standard texts yourself and copy them into purchasing documents.
    Master records
    Database fields
    Activities
    Creating Standard Texts
    You can create your own standard texts via Tools ® SAPscript ® Standard text.
    Inserting Standard Texts
    You can insert your standard text on the long text screen via Insert ® Text ® Standard.
    For more information, refer to the Basis documentation under BC Word Processing with the SAPscript Editor:  Including Texts.
    You can display the print preview via Text ® Print ® Print preview.
    Inserting Texts from the Master Record
    There are three ways of linking texts from a master record with a purchasing document. The relevant settings are made for each text type in Customizing for Purchasing. The indicator in the status column shows the nature of the linkage.
    Option                                              Indicator in status column
    The text is copied:               
    It is then independent of the text                 None
    in the master record. Changes to
    the text in the material master record
    have no influence on the text in the document.
    The text is displayed only:
    It cannot be adopted.                                          N
    The text is offered for copying:
    It can be copied via Header or Item ® Texts ® Adopt text. (In requisitions: Goto ® Texts ® Adopt text.) Changes made in the master record will also be adopted in the document until such time as you copy the text.
    Inserting Texts from Database Fields
    You can include the content of a database field at any point in the text on the long text screen. A value specific to the relevant document is displayed in the printed document.
    Choose Insert ® Symbols ® Program symbols.
    Choose DDIC fields.
    Search for the relevant table/structure (in the case of PO items, this is EKPO) and then choose ENTER .
    Choose the relevant table field.
    Choose Text ® Print preview to see the print preview.
    Reward if useful
    Aasif

  • Is it possible to programatically add tab pages on tab control

    Hi All,
    Is it possible to programatically add tab pages on tab control? If yes then how?
    Thanks & Regards,
    Shrinivas

    Doing this will require the use of VI server and methods and properties.  First, some questions:
    Is the number of pages you may need unbounded?
    Do you have a maximum number of pages you need to display at any one time?
    If the answers are no and yes, then you can create a tab control with the maximum number of pages you need, and hide or show the pages, as necessary. To hide or show pages, use the Pages property to get references to all the pages.  Use Index Array to select the page you want to show/hide, then use its Page Visible property to show and hide it.
    You can also get a lot more dynamic, if you number of pages you need to show at any one time is less than the total number of pages.  In this case, you will want dynamic page contents and tab name.  You can set the tab name by Page Label property of the page (right next to the Page Visible property).  You can make the content dynamic by using a subpanel as the only contents of the page.  You can find out about subpanels in the LabVIEW help or this post.
    You also need to ask yourself whether a tab interface is the best one for your application.  I have usually found that if I need to show and hide a lot of tabs, I would be better off with a subpanel for my content and a text or menu ring the select the content.  Tree controls also work nicely for selection.
    Good luck!  Let us know if you need more help.
    This account is no longer active. Contact ShadesOfGray for current posts and information.

  • Issue in wrapping of text in TextEdit control

    Hi,
    I'm developing an occasionally connected application using NetWeaver Mobile 7.1. In one of the view, I use TextEdit control to display the address information where the address is a multiline text data. During testing of the application in the simulator, the wrapping of text in the TextEdit control is not working properly. The wrapping property of TextEdit control is set to "soft" but the text is not getting wrapped. Even I tried the other option "hard" wrapping but it throws some error while building of the application.
    Please suggest a solution to do wrapping of text using TextEdit control.
    Thanks in advance.
    Regards,
    DVR.

    Hi Nipun,
    The rows and cols properties are already set and also the data is multiline but the text is not wrapping.
    Say the properties of a TextEdit control rows is "4" and cols is "30" was set. The data is also a multiline text say each line has more than 30 characters. During wrapping of text with in TextEdit control the first row should have only 30 characters and rest should be wrapped off to the next row and so on.
    But during execution what happens is the text is not getting wrapped instead the first row itself has all the characters of first line of the text and second row has next line of text and so on. The text in a row can be scrolled through using horizontal scrollbar.
    My need is the horizontal scroll bar should not come and the text need to the wrapped off with number of cols specified.
    Regards,
    DVR

  • JS scripted needed to add custom text plus filename to file info in document title

    Would greatly appreciate any help with this one...
    JS script to add custom text plus filename to file info in document title
    many thanks

    Super :O)
    I have a folder of say 50 images and I want to run a JS script batch
    example in the document title :  image Nr 81205
    custom text is "image Nr" +  file name "81205"
    activeDocument.info.title =" image Nr" + decodeURI(activeDocument.name);
    would this be correct without seening the file ext
    many thanks

  • Can I add a text form field in Photoshop that can be edited in Acrobat reader?

    I design coffee labels with Photoshop then send them off to the printers. The printers then open up a PDF and put in the best before date before printing. At the moment I have to add the text form fields using Acrobat Pro after i've saved the photoshop document as a Photoshop PDF. The problem is if I want to edit the labels at a later date, I have to re-add the text form fields with Acroabat again. 
    Can I add a text form field in Photoshop that can be edited in Acrobat reader? Is it better to use another program for this task?
    Thanks in advance
    Ian

    As A1's Calculate script, under "Simplified field notation", enter:
    A * 0.8
    The same goes for B1 and B, resp.

  • How to add a field and table control to BP transaction.

    Hi,
    I have a requirement to add a field and table control to the 'Control data' tab of the Transaction BP.
    Can some on please help me if having a solution and with any relavant documents.
    Thanks in advance.
    Raj & Khader.

    Also explore with EEWB tcode.
    Refer this threads
    Re: EEWB
    Created New fields in Business Activity with EEWB
    Cheers
    Manohar

  • Everytime i try to add a text box the program crashes.  Why and how do I fix it?

    Since I purchased and installed Adobe Photoshop Elements every time I try to add a text box the program crashes.  Why and how do I fix it?

    TeeKnows wrote:
    Debit cards are accepted in the iTunes store.
    No longer accepted for NEW accounts, however if a debit card were associated with the account BEFORE this change, they can still be used.

  • How do I add multiple text block records from text file?

    The data manager documentation (page 151) for MDM 5.5 SP3 indicates that one or more new text blocks can be added to the Text Blocks object table from files. It is noted that the files must be plain text files.
    I use notepad and create a text file with two lines as follows:
    Test 1
    Test 2
    When I try to add the text blocks following documentation mentioned above, it only adds one record for the Data Group I have chosen and the record contains the entry "Test 1" from the first line in the text file.
    How can I add multiple records to the data group from a file?

    From my testing it appears that you need to have one text file per text block record in Data Manager.
    I wrote VBA macro to so that I could input my text blocks into an Excel spreadsheet and then the macro will take the contents of each cell in a highlighted column and create one text file per cell.
    Then using Data manager, I can select all of the text files at once and it will import them, creating one record per text file.

  • How do I add a text box to an ibook?

    How do I add a text box to an ibook page?

    Not very user-friendly IMHO, but ok here goes:
    Place a picture of the band in your body background's CSS
    with repeat:
    no-repeat. Then add a scrolling division to your html page -
    like so:
    <div align="right">
    <div style="font-family:'Verdana', 'Arial', 'Sans-serif';
    font-size:12px;
    color:#FFFFFF; text-align: left; background-color:#000000;
    border:2px solid;
    overflow: auto; padding:10px; width:auto; height:200px;
    border-color:
    #333333;"><h3>Your heading goes
    here</h3><br><br> More text goes
    here<br><br> and more text goes
    here...</div>
    <p> </p>
    <div style="font-family:'Verdana', 'Arial', 'Sans-serif';
    font-size:12px;
    color:#FFFFFF; text-align: left; background-color:#000000;
    border:2px solid;
    overflow: auto; padding:10px; width:auto; height:200px;
    border-color:
    #333333;"><h3>Your heading goes
    here</h3><br><br> More text goes
    here<br><br> and more text goes
    here...</div>
    </div>
    --Nancy O.
    Alt-Web Design & Publishing
    www.alt-web.com
    "strippedman" <[email protected]> wrote in
    message
    news:g4h1ac$pqh$[email protected]..
    > I'm looking more for something like this:
    >
    > www.muse.mu
    >
    > See how there's essentially a picture of the band in the
    background and
    then
    > two text boxes with scrolling capability on the right?
    That's all I
    want...two
    > locked scrolling text boxes on a picture...without using
    flash.
    >

  • How to add a column in table control

    Hi ,
       Can any one tell me how to add a column in table control? My requirement is to add two columns ( custom fields ) into table control ( It is a standard program). I have added the column in the table and also in the table control. But when I am running the standard program, The newly added column is not there. But I have added in the perticular screen. Change is not reflected.
       Can anyone help me on this please.
    Thanks in advance.
    Regards,
    Lakshmi.

    Hi,
    Ensure the following :
    1. After adjusting the database, you`ll have to use the database utility and activate the table.
    2. If you have changed the standard screen, in tcode se80 -- right click on the program and click activate all. This activates all objects related to that program.
    Now execute the program.
    Reward if helpful.
    Regards

  • How to add Predefined PDF Form as a Template in BIP - 11g

    Can anybody please help me to understand how to add Predefined PDF Form as a Template in BIP - 11g and how to map the Form fields with the Data Elelment.
    I tried it with 10 g set up as well, but I found following things
    1) PDF form template mapping was only available whenever we provide sample data with the same filed name and also number of fileld should be same.
    2) According to user manual that I have, it says that whenever I click on the form field while mapping the form field data elements, it should open a new window having the corresponding mapping details.
    But in my case no new window was opened when I clicked on the form field while mapping.
    Please help me out since i am beginner with BIP and have to move forward with Predefined PDF Form as a Template in BIP - 11g.

    I am new to BIP-11g. But i have created rtf, pdf templates in 10g. I am migrating reports to 11g. If you know How to add Predefined PDF Form as a Template in BIP - 11g , Please let me know.
    In 10 g you need to do the following things
    1. First you need to create data template.
    2. Then you have to upload pdf template.
    3. After you have uploaded the pdf template, Map Form Fields tab will appear. Then you can map the form fields.

Maybe you are looking for