Trainferry
New Member
- Joined
- Feb 6, 2018
- Messages
- 2
Hello all,
I would like to create a code in VBA to complete some fields in a webform. Due to privacy-matters I can't copy the whole code of the form. However I can sent the part, where I'm stuck. To complete the webform it appaers I should note something like this in VBA.
<code style="margin: 0px; padding: 0px; border: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; line-height: inherit; font-family: Consolas, Menlo, Monaco, "Lucida Console", "Liberation Mono", "DejaVu Sans Mono", "Bitstream Vera Sans Mono", "Courier New", monospace, sans-serif; vertical-align: baseline; white-space: inherit;">IE.document.getelementsbyID("ABCDEF").Value = "XYZ"</code>In the source code it seems the elementID would be "Agent_name". However when submitting excel, the webform does not take over the value.
This is the source code:
<tr id="Agent_Name"><td class="FieldLabel"><label class="EditingFormLabel" id="p_lt_ctl03_pageplaceholder_p_lt_ctl00_On_lineForm_viewBiz_Agent_Name_lb" for="p_lt_ctl03_pageplaceholder_p_lt_ctl00_On_lineForm_viewBiz_Agent_Name_txtText">Agent name:</label></td><td class="EditingFormValueCell"><div class="EditingFormControlNestedControl editing-form-control-nested-control" id="p_lt_ctl03_pageplaceholder_p_lt_ctl00_On_lineForm_viewBiz_ncpagent_name">
<input name="p$lt$ctl03$pageplaceholder$p$lt$ctl00$On_lineForm$viewBiz$Agent_Name$txtText" class="form-control" id="p_lt_ctl03_pageplaceholder_p_lt_ctl00_On_lineForm_viewBiz_Agent_Name_txtText" type="text" maxlength="500">
</div></td></tr>
I hope someone can help me with this.
Many thanks in advance!
I would like to create a code in VBA to complete some fields in a webform. Due to privacy-matters I can't copy the whole code of the form. However I can sent the part, where I'm stuck. To complete the webform it appaers I should note something like this in VBA.
<code style="margin: 0px; padding: 0px; border: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; line-height: inherit; font-family: Consolas, Menlo, Monaco, "Lucida Console", "Liberation Mono", "DejaVu Sans Mono", "Bitstream Vera Sans Mono", "Courier New", monospace, sans-serif; vertical-align: baseline; white-space: inherit;">IE.document.getelementsbyID("ABCDEF").Value = "XYZ"</code>In the source code it seems the elementID would be "Agent_name". However when submitting excel, the webform does not take over the value.
This is the source code:
<tr id="Agent_Name"><td class="FieldLabel"><label class="EditingFormLabel" id="p_lt_ctl03_pageplaceholder_p_lt_ctl00_On_lineForm_viewBiz_Agent_Name_lb" for="p_lt_ctl03_pageplaceholder_p_lt_ctl00_On_lineForm_viewBiz_Agent_Name_txtText">Agent name:</label></td><td class="EditingFormValueCell"><div class="EditingFormControlNestedControl editing-form-control-nested-control" id="p_lt_ctl03_pageplaceholder_p_lt_ctl00_On_lineForm_viewBiz_ncpagent_name">
<input name="p$lt$ctl03$pageplaceholder$p$lt$ctl00$On_lineForm$viewBiz$Agent_Name$txtText" class="form-control" id="p_lt_ctl03_pageplaceholder_p_lt_ctl00_On_lineForm_viewBiz_Agent_Name_txtText" type="text" maxlength="500">
</div></td></tr>
I hope someone can help me with this.
Many thanks in advance!