You're welcome Amin! :-)
You're welcome Amin! :-)
Hello Amin,
Certainly we need to test it, because, some unexpected problem can occur. However, I try to create an Cordova app from the scratch using the command line. Then, I put an "www" of an App Builder's app inside the first created one. In the index.html of the first app I place an iframe, and, point the "src" of the iframe to the "index.html" of the App Builder's app.
The above works, Amin. Of course this requires more tests, as I said, but, in principle, work here with simple sample apps.
On the other hand, if we can see working an AB app running in an non AB app, probably we can do also the contrary: an non AB app, running in an AB app.
You can download here an "hello" Cordova app which run in an Iframe the "Database" sample of AB:
https://www.decsoftutils.com/temp/hello.zip
https://www.decsoftutils.com/temp/hello.apk
Anyway, I start to think that certainly insert an app inside an iframe may can have some unexpected result. On the other hand, what happen if the inserted/embedded app have some specific Cordova requeriments? Maybe its enough than the first app (the host app) add the right stuff (like plugins) and can these be available for the inserted app?
The above questions must be answered... so, in principle, depending on the app, the above iframe solution can be good or not. Apparently the sample that I prepare works as expected.Hello Amin,
I think you can do it by including one app's files inside the other app's files, so, the second one can reach the first one files and viceversa. Then may you can use an Iframe control in one app to load certain app's file URL of the other app. This probably can be the most easy way to do it, but I am not sure if can be enough or not...
Hello Amin,
Yes; you are right. Apparently the Cordova's "Whitelist" plugin is required... and, for that reason, App Builder includes it by default in both the Cordova's configuration file and the generated BAT and SHELL files... so you are not using these files Amin? Anyway, glad to know that you got it.
Hello Amin,
An HTTP 404 error code means that the server can't be reached, certainly. Maybe are you using "local URLs" (that points to your local server) when debugging? Then you must prepare the right URLs with to reach the real internet server. We can set the URLs of HTTP Client controls in design but also in runtime, with the "HttpSetUrl" action, for example.
On the other hand, you mention Phonegap. I think this doesn't made any difference, but, consider to use Apache Cordova instead: App Builder is better integrated with Apache Cordova. But, again, in principle, this do not matter. Additionally, check if your device have an internet connection! But an 404 error is clear: the server can't be reached.
One more thing: App Builder nor Apache Cordova nor Phonegap, don't touch the URLs of the HTTP Clients, so, probably the problem is not specifically related with these software. Just be sure that you are trying to use the right URLs, Amin.
Hello Paolo,
I understand. Well. It's the first time that I know about that resource or "codelab". From the app's options (look at the app's options dialog, under the "WebApp > Progressive WebApp"), you can check the appropriate checkbox in order to create an Progressive Web App manifest. But, I am not quite sure if this is exactly what you wanted, since this alone causes that some browsers shown to the user, in the context menu, a way to add the app's icon in the device home screen.
Honestly, Paolo, I don't know what to say... you need to study the "codelab" and try to folow the instructions. I have no time right now to try that for you. For example, may you need to create an specific manifest, or add some pure Javascript code, and, maybe something more. The point is: if that can work in an HTML app... then must work in AB apps too. So please, study the instructions, do your tests, and, if you find some specific problem, I will try to help you.
Maybe I can take a look when I have some free time... but, certainly, the project don't appear quite interesting to me at a first view: apparently it's limited to one sole browser, which is not very good, in my opinion. However, again, try it and, if you need some specific help, post it here in order to try to help you.
Hello Paolo,
I am not quite sure if what you wanted is to show some kind of advertisement or if you refer to local notifications. In the first case, you can take a look at the AdMob sample, which uses certain Apache Cordova plugin and allows to shown "interstitials", which maybe is what you wanted.
If you refer to local notifications, then you must study this Apache Cordova plugin, for example. You can get some help by take a look at the "CordovaPlugins" sample, or other samples like "SendSMS", which also uses Apache Cordova plugins.
If you refer to other thing, please, post it here and I will try to help you.
Hello Bryce,
Maybe this is not an easy to answer question. That is, what HTML Compiler uses is the latest available WebBrowser component of Microsoft Windows, setting the "emulate" option to be Internet Explorer 11. But, if I am not wrong, we can't say an specific version of Javascript which is used by this browser, because probably support various of them in various ways.
Do you have some specific problem Bryce?Hello Paolo,
You can use the "popover" related variables, like in the below code:
Take a look at the General considerations topic in the controls' help, in which these and other common variables are explained.
Hello Amin,
Hi David,
Thanks for your assistance, could sort that out with [App.CurrentView], kept the dropdown in the MasterView and refreshed proper HttpClients based on the activeview response any time the master button is hit.
Thanks a mill,
Añways thanks you for your support. Probably you already know it... but we have another maybe interesting app's event: ViewChange· Maybe not useful in your specific case here, but, who know, maybe can be useful in the future.
Hello Amin,
Sure David, I understand that and I know I can call the HttpClients by other events and not just the show. The point is that I have near 20 Https clients, in 8 views. Refreshing the view, or triggering view's show event, by dropdown itemclick event, could simply fix the problem. Now I need to go page by page and call each HttpClient at its own view. Tried to bypass it but seems like there is no escape from reproducing it all.
What if you place the code of the Show view event in an app's function? Then you can call to the app's function in the Show view event and also in other places too. But anyway, supose that in the Show event you prepare certain HTTP call, depending on certain variables, etc. In principle, you can also prepare another HTTP call with other dependencies, new argument values, etc., in other possible place. Anyway, maybe in your case it's possible to use one app's function and then call to it in the Show view event and other possible places.
Out of curiosity now, is it possible to read what view is active? So lets say if I keep the button in the MasterView is there a way that I know from what view it has been clicked? so in the ItemClick event of the dropdown, I will know in what view click has taken place and so what HttpClient should be recalled?
About to know the current view, we have the [App.CurrentView] global app variable, which may can be useful.
Hello Amin,
Maybe I can explain a bit more about the "reload" view... the point is that, maybe, in the Database sample, you see the HTTP call in the Show event of the views... but this is just the way in which someone (me) decide to construct the Database sample.
What matter here is that the HTTP call to feed the Report's Data variables can be executed in any time, not only in the Show event of the views, or when the view is loaded. We can made any HTTP call, any time we need and without reload any view.
Hello Amin,
About the first issue, I don't think that you need to reload the view at all. In other words, if you want to perform another HTTP call or just play with the Report's Data variable, the Report control must reflect the changes. In my opinion you must not deal with the view load or reload, but, just made the right HTTP calls or change the Report's Data variable when needed. You can do it in the same view various times without problems. So you can change the subject that you need to "query", and then perform the right HTTP call to feed the Report's Data variable with the new data.
About the Master view, certainly, there is just one right now. Can be useful, but, if we use it "as is", expecting that all the controls placed in the Master view are placed in all the views in which the Master view is used. I want to think around this, Amin, since another customers told me about this before too. I am not quite sure about how I can implement it, nor when I have the required time to put my hands on, so I can't promise nothing, but I will try.
About the Undo, I think you refer to the designer Undo, not the code editor Undo. The code editor Undo and Redo works more or less as expected in an common code editor. The designer Undo don't work like that, Amin. They try to be useful, but, certainly not all the times we get the same results that we can expect in an code editor, in fact, we only have an Undo in the designer, and not an Redo. Something else to be improved when possible, yes.
Please, try to modify the Report's Data variable by made HTTP calls (to receive the data to place in the Data variable) or just to change the Data variable (which is an Array variable after all), in one word, try to do what you wanted forgetting the "reload" of the view. You must look in this way... and then please, post here if you need some particular help or something else about this question. I will try to help you when possible!Hello Amin,
Certainly, the error is clear (this time): we try to access to an "Hidden" propery of an variable which is not the expected one, because is undefined or null. I think that the problem is caused with the ReloadView action, because, this is an little special action, that must be use with caution.
So what happen? In fact, the ReloadView action causes that the entire app is are loaded again. This behaviour (which is the expected, on the other hand), can cause problems like you describe, Amin. The solution, in your cause, may it's try to avoid the ReloadView usage.
Please, try it and don't hesitate to post here if you think that I can help in something.
About the various master views... certainly something like that is not possible. It's an interesting concept, and I will try to take a look at that. Maybe I can add something like that, must be study when possible and look for some possible way to do it.
Of course, depending on what you wanted, maybe we can also find another possible approach too, so, if you think that can detail a little more exactly what you wanted... maybe I can help in something.
Hola Julio,
Bueno, el tutorial lo enlacé pensando más que nada en que se muestra cómo usar una función de la app desde Javascript, y, creo que también cómo acceder a variables de la app. Por lo demás, las acciones StartJS y EndJS están para usarlas, por supuesto: como todas las acciones de AB terminan traduciéndose al correspondiente código Javascript, al final, todo será código Javascript. :-)
Everybody can read the DecSoft support forum for learning purposes, however only DecSoft customers can post new threads. Purchase one or more licenses of some DecSoft products in order to give this and other benefits.