Multi-Line Text Box promoted to SharePoint multi-line column and editable? RRS feed

  • Question

  • I posted this question on an existing old thread, but thought I may get more help making it its own new question.  For starters, I am using InfoPath 2007 and MOSS 2007.

    I need to have a multi-line text box in InfoPath (can be regular text box supporting multi-line, or can be rich text field - I don't really care) that is promoted to SharePoint as multi-line text (need more than 256 characters) AND can be edited in SharePoint.

    I have tried all of the approaches suggested in earlier threads, but none of them let me edit the multi-line text field in SharePoint without cutting off at 256 characters.  When I promote a multi-line text box, it automatically promotes it to a single line text box in SharePoint.  I can check the box to make it editable, but lose all text after 256 chars.  If I switch it to a Rich Text box, I can promote it and SharePoint reads the full text, but the check box to make the field editable in SharePoint is disabled for Rich Text fields (at least in IP 2007 - not sure about 2010).  I tried the work-around suggested - to create the site column first, and then promote the field to a new column and call it the same thing.  Interestingly, the text from the Form shows up in BOTH fields (the site column I created which supports more than 256 chars, and the newly promoted column), but editing the site column does NOT update the Form field.

    I need to be able to update the field in SharePoint, because I am using a Workflow to copy the data into the From.  I am ready to tell the owner of the requirement that there is no way to edit an InfoPath multi-line text field (greater than 256 chars) through SharePoint, but before I do am hoping someone has a suggestion of a way that would work.


    Sunday, March 17, 2013 6:52 PM

All replies

  •   string targetListTitle = string.Empty;
                if (Field.GetCustomProperty("TargetList") == null)
                    //this.Page.Response.Write("Select target list");
                    targetListTitle = Field.GetCustomProperty("TargetList").ToString();
                if (this.ControlMode != SPControlMode.Display)
                    //add script manager
                    if (ScriptManager.GetCurrent(this.Page) == null)
                        ScriptManager sMgr = new ScriptManager();
                        sMgr.ID = "ScriptManager1";
                        this.Controls.AddAt(0, sMgr);
                    //create table & ui elements
                    this.table = new HtmlTable();
                        using (SPWeb web = SPContext.Current.Site.RootWeb)
                            SPList targetList = web.Lists[targetListTitle];
                            SPQuery query = new SPQuery();
                            query.Query = "<Where><Neq><FieldRef Name='Title' /><Value Type='Text'>All</Value></Neq></Where><OrderBy><FieldRef Name='Title' Ascending='True' /></OrderBy>";
                            this.items = targetList.GetItems(query);
                            foreach (SPListItem item in this.items)
                                HtmlTableRow row = this.getRow(item);
                    catch (SPException e)
                else if (this.ControlMode == SPControlMode.Display)
                    SPFieldMultiColumnValue mcv = (SPFieldMultiColumnValue)this.ItemFieldValue;
                    for (int i = 0; i < mcv.Count; i++)
                        LiteralControl lc = new LiteralControl();
                        lc.Text = mcv[i];

    Sunday, October 19, 2014 11:18 AM