Hi there,
I am developing a piece of code that enters strings into a collection of elements on a Share Point form.
All was going well until I hit a couple of <TextArea> elements and am having considerable trouble entering text into them.
The first textarea was a name picker which performs a lookup to Active Directory.
After much trial and error, I was able to write to this textarea input box by:
Code:
...
Set htDoc = ie.Document
Set txtArea = htDoc.getElementById("uniqueID_UserField_downlevelTextBox")
txtArea.previousSibling.innerText = "string I am sending"
...
The second text area is proving to be far more tricky. It looks like a rich text editor:
The problem with text area elements, is that you can't just set a .Value. While any string that is sent to textarea.value is stored, it is not reflected on the page. And on form submit, it is as if no data was entered into the field. So far, no methods have been successful.
Does anyone know how these "Rich Text" textarea elements in SharePoint work? It must store the text somewhere, but I haven't been able to figure it out.
Any help would be greatly appreciated.