Clearing the input field after task is successful - fltk

I would like to clear the input field of my app when user clicks the save button and the input values are successfully saved.

just use input->value(""); that´s all.

Related

Blue Prism Write to Web Client

Has anyone had any problems writing data to a web client data field?
Having spied the field to be written in, the write action correctly writes the value from the data item into the web field. We then "Save" the value in the field by clicking the Save button. This is when the value reverts back to the value that was previously in the field and does not save the new value.
Copying the value from the data item and pasting it directly into the web field and hitting save works fine, but for some reason when Blue Prism does the write action and then save, the new value is not saved.
Any suggestions?
This is probably due to the way the web application is coded - specifically, the data in the box is not acknowledged until a keydown event (or similar) is fired. When you copy/paste the data into the field, it fires a similar event where it believes the user to have interacted with the field.
The solution for this type of field is to use the Send Keys or Global Send Keys functionalities of Blue Prism to send the desired text.
It happens when the target application uses java script events to sense the changes in the element. To handle this , you have to use the send keys in following format.
1. Focus the application / Control
2. Send Global mouse click centre to the element
3. Send "Sendkeys" to the application now.
4. Focus a dummy element in the page to let the page sense your input.
If the old value is already higlighted when the spied field is selected, try getting BP to delete it first, then paste in the new value, then click on the field again, then save. If this doesn't work, then uncheck the URL attribute of the application model you are using for the spied field and try this again.

AlertService directive in JHipster

I am using JHipster 3.3.0 and generated code using JDL.
Out of the box, each entity has its own popup dialog page for editing and saving data, i.e. {entity}-dialog.html. And after clicking the Save button, the dialog will close then the entity list page (i.e. {entity}s.html) will display the alert message 'A new <entity name> is created/updated with identifier {primary key}' to indicate outcome of save by using <jhi-alert-error></jhi-alert-error>.
Now I am implementing a one-to-many relationship for 2 entities, say User and Account(i.e. a User can have many Accounts)
such that the editing and saving of both entities happen in the same User page(i.e. User-dialog.html).
All Accounts of the User are displayed in an Account table, each row of the table will have a Save button to save data
of the Account after editing the data in the row.
This is all working fine. However, I noticed after clicking the Save button of Account row, I can see the background User list page
displaying the alert message mentioned above rather then in the current page.
I can't figure out how to display the alert message in the current page as opposed in the entity list page, which is the
default behavior.
I am missing some logic here. Any idea?
Basically, the <jhi-alert-error></jhi-alert-error> in my <entity>-dialog.html page is ignored and won't display message for outcome of successful save except for error message from Form validation.
Thanks in advance,
Sam
Ooops,silly me. Just found the answer.
The alert message 'A new is created/updated with identifier {primary key}' was displayed because the tag <jhi-alert></jhi-alert> was used, it was never
<jhi-alert-error></jhi-alert-error>.

How to disable the whole page?

I have a field where a customer number is required. When the user leaves the field in the onblur event I need to run some code, in this case check if the given number is already in use. The problem is the codes needs some time to complete. For this short period the user should not be able to make any input. Also I'd like to display a gif.
There is a genius snippet on XSnippets called "Standby Dialog" (https://openntf.org/XSnippets.nsf/snippet.xsp?id=standby-dialog-custom-control)
If you implement this on your page (preferably as custom control) you will get an overlay everytime a partial refresh happens. If you init a partial refresh when the user blurs the field you will get what you want.

Refreshing the xpage document & showing the computed fields immediately without closing & reopening the xpage document

I am working with xpages and need a unique number to be generated for each document. After saving the document, I want the user to be on the same page viewing the generated number. For this I have used the a action group on the submit button - 1) first action is a simple action which is saving the document. 2) Next action is script editor where I am calling my number generation agent 3) The last one is a simple action which is changing the current document mode from Edit to Read so that the user is still on the same xpage document after saving. But I see that the document is saved properly and also changed to read mode but I cant see the number generated. But if I close the document & open it again I see that the number is generated. I want this number to be shown without closing & reopening the document. Any help is appreciated.
If you're updating the backend Document datasource, you'll need to either fully reload the page or close and re-open. Try setting the unique reference on the dominoDocument datasource and re-saving that. Alternatively, build the relevant URL to the XPage with the relevant documentId parameter and redirect accordingly.
You can put a Full Upload at your onClick event or a partial Upload.
With the partial Update will update just one element of your page, if your computed fields are inside this element they will be updated.
http://i.stack.imgur.com/g0DA7.png

Automatically submit/save InfoPath form to SharePoint

I'm designing an InfoPath form that will be saved to a SharePoint 2010 library. This will occur automatically when the user performs a certain action on the form. If the user closes the form, it should prompt them to save changes and if necessary, save to SharePoint.
Problem is I don't want the users to have control over where the form is saved or what it's called, as I intend to handle that automatically.
Now it's possible to capture the onSave event and perform a custom action. But if I did this, I'd need to set the property to cancel the save event, or the user will be shown the "save file" dialog box anyway. But cancelling the save event causes InfoPath to display a warning to the user - "InfoPath cannot save the form. The OnSaveRequest event handler returned a value indicating that the save failed".
Is there any way to facilitate custom save events while still allowing the user to use the save button? It's also important that the user is promted to save changes if they try to close the form, however disabling the save option removes that prompt.
I worked out what to do. The solution is much simpler than I thought.
Capture the onSave event, perform the custom save action, set the cancel flag to false, and remove the call to PerformSaveOperation(). This eliminates the mentioned error message, and doesn't prevent the user from closing the form.

Resources