I'm currently doing some web automation. My recent problem is to pass content to tinymce text area with excel VBA. After searching all over the internet, I think the possible answer can be found here: How can I pass variable parameters into a Javascript Function using Excel VBA.
However, I tried to do the same as mentioned in above link but failed.
IE.Document.parentWindow.execScript "tinyMCE.get('Server').setContent(" & inputStr & ")", "JavaScript"
Currently, the variable inputStr was declared in VBA as below:
With dataSheet
inputStr = .Range("B35").Value
End With
Does the variable need to be declared as javascript variable? If so, how I can do that in excel VBA?
Please help.