Jump to content

Recommended Posts

Posted

Hello, im new here. I want to know if its possible to send a value (string, number, etc) from my application to an web page input form.

 

This is the html of the input that i want to pass the value: <input name="nmrProtocolo" type="text" size="12" maxlength="12" value="">

The page have this input and a Search Button.

 

What i need -> I click on a field on my unidbgrid and then this page open with the number of the field on the input field. I only need to click on the search button on the page. Sorry for my english and explanation.

Posted

Hi,

Please explain more, What do you mean by the web page?

May can help, try:
For example:

procedure TMainForm.UniButton1Click(Sender: TObject);
var  yourInputElemName, newValue: string;
begin  
  yourInputElemName := 'nmrProtocolo';  
  newValue := 'Search value';  
  UniSession.AddJS('var _textEl = document.getElementsByName("'+ yourInputElemName +'")[0]; _textEl.value="'+ newValue +'"');
end;

Best regards,

Posted

Hi,

 

It's cross-domain issue. You can almost embed any iframe but, if domains differ, you can not access the frame e.g. execute JS, modify DOM etc.

 

Best regards,

  • Upvote 1
  • 7 years later...
Posted

hi Georges, did you succeed?

i have HTMLFrame that sends data to some object in the form.

i see it on the browser, but I don't see it in the UNIGUI form (server side)

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...