UI5 – Using the ValueHelpDialog

Home / Blog / UI5 – Using the ValueHelpDialog

Well, as usual, this adventure took a lot longer to figure out than I expected.  I walked into this thinking, I just want to add the equivalent of F4 to my UI5 application.  It took a little digging to find the “right” way to do this.  The first method I found was this:

http://scn.sap.com/blogs/ui5-for-abap/2013/06/25/how-to-implement-value-help-f4-with-sap-ui5

I was excited, this step by step would be perfect.  However, during one of my OpenSAP classes, they talked about NOT using the sap.ui.commons library, as it is no longer being enhanced.  So, short story, I found a way, but it wasn’t really the smart way to implement going forward.  Luckily for me, the service on the backend of the gateway was pretty straightforward.  I decided to create 2 examples.  One for plant and one for order type.  This way I could test how dynamic I could make this…  But I’ll talk more about that in another post.  Today, I just want to talk about getting the ValueHelpDialog working in a static method.  This took more effort than I expected.  I finally found an example in the UI5 library to get me started.

https://sapui5.netweaver.ondemand.com/explored.html#/entity/sap.m.MultiInput/samples

So, I set and mimicked this example.  One of the big things, don’t forget the “sap.ui.comp” library.  I fought weird syntax errors until I figured it out :).  Once I got their JSON example working in my model, I began to deconstruct it, at least enough to input my own gateway model into the results, change the table etc…

Tomorrow, I’ll take about making it dynamic…  this took way longer than I expected, but only because I keep adding new functionality…  more tomorrow.

Thanks for reading,

As always, thanks for reading and don't forget to check out our SAP Service Management Products at my other company JaveLLin Solutions,
Mike

Leave a Reply

Your email address will not be published. Required fields are marked *