B4J Library [ABMaterial] Framework for WebApps

Discussion in 'B4J Libraries & Classes' started by alwaysbusy, Nov 5, 2015.

  1. alwaysbusy

    alwaysbusy Expert Licensed User

    Can you give me some more info about this? I have seen a similar thing myself, but I also noticed this only happened when I was debugging a lot and I was starting and stopping the server a lot, while keeping my Chrome browser open, which sometimes confused the jServer library (jetty). ABMaterial has a build in 'timer' in the browser part where, if it loses connection starts a timer every 3 seconds to reconnect. You can see this in the b4j_ws.js file in the www/js/ folder.
     
  2. Gabino A. de la Gala

    Gabino A. de la Gala Active Member Licensed User

    I send you a mail with problem detected with the update of tables.

    Thanks for your work.
     
  3. alwaysbusy

    alwaysbusy Expert Licensed User

    @Gabino A. de la Gala I'll send an update in about half an hour. Seems a big chunk of code was somehow deleted in the lib I've send you. (e.g. I don't think that you have the method called tbl.SetString(row, col, value). Also, I forgot one crucial piece of information. I'll explain more in the mail.
     
  4. Roberto P.

    Roberto P. Well-Known Member Licensed User

    like you said, if I keep the browser open and without any operation, after about 20 minutes the system is no longer available. If I press a button appears red "Disconnected". If it happens, I do print screen.

    I am using the example standar.

    I try now with the new version that you sent and if it happens, I am sending my ip public server.

    Hello
     
  5. Roberto P.

    Roberto P. Well-Known Member Licensed User

    Hello
    I also tried the new version and the problem remains.
    If you leave the brower any page ABMaterial demo open for about 20/30 minutes crashes.
    This problem is much thanks and should be fixed.
    thank you
    Roberto
     
  6. Roberto P.

    Roberto P. Well-Known Member Licensed User

    Alain
    would be interesting to also implement Ajax, if possible, to avoid that when you press a menu to be recharged all pages, not just the modified part.
    I hope you feel this interesting.
    Thank you
     
  7. alwaysbusy

    alwaysbusy Expert Licensed User

    @Roberto P. Nothing about your crash problem has changed in v1.02. I don't seem to be able to reproduce it over here. Page has been open for hours and still does what it has to do. Also, the server app does not report a problem.

    Can you give me the exact steps you're doing? I need as much information as possible. Some things that may help identifying the problem:
    Do you see disconnects in B4J?
    Do you get crash logs in B4J?
    Using chrome, pressing F12 and looking into the console, do you see crash logs?

    As for Ajax. As long as you stay on the same page, there is Ajax-like behaviour. That is why components have a refresh() method. e.g. if you do tbl.refresh(), the page is not reloaded but only the table is changed using DOM manipulation. This is also why you should avoid page.refresh() as this is almost the same as navigating to the page again.

    Only when you use the navigation bar the new page is loaded (but this is normal, as it actually navigates to another html page). It does not recharge all pages, just the page belonging to the menu item. And it is impossible to put all the b4j pages into one html file. I've tried that in the beginning with iFrames and it immediately was causing a lot of trouble. Also, it was much harder to build WebApps in B4J. It was very easy to write code that crashed the whole app (e.g. using the same id for a component between pages).

    It was a matter of balance of creating a framework that is easy to use in B4J (server side) and what happens on the client side (browser). I decided to use B4J to build ABMaterial to make it easy for the programmer. It does not, like B4A or B4i, 'translate' the B4J code to another programming language.

    So in short, no. ABMNavigationBar behaviour will not change, at least not in the near future.
     
  8. Gabino A. de la Gala

    Gabino A. de la Gala Active Member Licensed User

    Tables work fine yet!!!

    Thanks!!!
     
    alwaysbusy and Cableguy like this.
  9. billyrudi

    billyrudi Active Member Licensed User

    Hi, AlwaysBusy,
    tank you you for all job!
    In my smartphone S6 edge the tostmessage when the text is long does not appear appear correctly. the panel's heigth does not increment itself so the text is out of it both upper than down.
    wath i can do?
     
  10. billyrudi

    billyrudi Active Member Licensed User

    AlwaysBusy,
    there is a way to inject javascript code to a page or a control?
     
  11. alwaysbusy

    alwaysbusy Expert Licensed User

    There is a future feature to do this, but THIS IS COMPLETELY UNTESTED! If it does not work, I'm not going to be able to look into this as I still got a lot on my plate.

    Page has two methods:

    page.AddExtraJavaScriptFile(fileName)
    page.AddExtraCSSFile(fileName)

    files need to be placed in the js folder and css files in the css folder.

    In theory, you should be able to use the default B4J page.ws.RunFunction() and page.ws.RunFuctionWithResult() methods.

    If it does work, it would be great if you could report this to the forum, as other could use it too.
     
  12. alwaysbusy

    alwaysbusy Expert Licensed User

    @billyrudi
    nothing I'm afraid. This is the case in the materialize.css framework I'm using and until those guys fix this, that's how it appears in ABMaterial.
     
    Last edited: Nov 19, 2015
  13. Roberto P.

    Roberto P. Well-Known Member Licensed User

    Hello
    I found the cause of the problem: using the program in an ADSL network without a fixed IP, the program disconnects.
    Fixed IP is ok.

    I understand that implementing Ajax is complicated, but it is nice to see the load of the entire site when running the press the main menu.
    We expect .....
     
  14. Gabino A. de la Gala

    Gabino A. de la Gala Active Member Licensed User

    Is it possible to raise a double click event in the cells of tables?

    If very complicated. Is there a way to set the duration of the click to jump event?.

    My request is the following. On the computer there is not much problem , since the scroll is done with the mouse and the corresponding displacement bar . The problem we have when we use the web from a smartphone or tablet, as we need to nibble on the grid itself to achieve vertical or horizontal motion. And that simple touch to "move" is considered like a click , triggering the event.
     
  15. Roberto P.

    Roberto P. Well-Known Member Licensed User

    hello Alain
    I requested hoping not to be too picky, but only to improve the framework!

    It would be helpful to have two new controls that do not think I have seen:

    - Autocomplete
    - TreeView

    Thank you in advance
    Greetings
     
  16. Cableguy

    Cableguy Expert Licensed User

    with all the feature requests being made, Alain will be "alwaysbusy" up until version 10000!!!
     
    jmon and Roberto P. like this.
  17. alwaysbusy

    alwaysbusy Expert Licensed User

    I would like to release version 1.02 somewhere next to the public, so if there are bugs (no new features!) in 1.02, please let me know.

    I would suggest you'll mail me the feature requests and bugs, because a lot is going to be lost in the forum I'm afraid.

    Maybe also keep posting it in the forum so everyone can see it do avoid doubles
    .

    Use the following subjects in the mail (I'm using rules in my email program to get things organized):

    Features subject line:
    ABMaterial FEATURE

    Bug subject line:
    ABMaterial BUG

    Also, know not all requests will make it. I'm currently working on the calendar control and it's a monster! Already spend every morning and night this week before and after my day job on it and there is still a lot, lot, lot of work to do on it!

    But it is starting to look nice into the framework:

    [​IMG]
     
    Last edited: Nov 20, 2015
    Peter Simpson, b4auser1, jmon and 5 others like this.
  18. Roberto P.

    Roberto P. Well-Known Member Licensed User

    Alain goes well, we will write email
    Great view of the calendar ... Fantastic!
    Thank you
    Roberto
     
  19. Gabino A. de la Gala

    Gabino A. de la Gala Active Member Licensed User

    Are there something similar to the event " keypressed " in edit fields?

    And so we can try to make suggestions in a list or something similar
     
  20. Gabino A. de la Gala

    Gabino A. de la Gala Active Member Licensed User

    You can highlight somehow selected in a list or table row ?

    Thanks.
     
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice