Alpha DevCon Engineering Roundtables
Results 1 to 18 of 18

Thread: Documentation - what's the asterisk for?

  1. #1
    "Certified" Alphaholic CharlesParker's Avatar
    Real Name
    Charles Parker
    Join Date
    Dec 2012
    Location
    New Orleans, LA
    Posts
    1,572

    Default Documentation - what's the asterisk for?

    On this page:
    https://www.alphasoftware.com/docume...ions/index.xml

    I see an asterisk as part of the function name, why is this? What does it mean? Also, some use case examples would be great on these - date and time math seems to be really troublesome for me!
    NWCOPRO Nuisance Wildlife Control Software-My Application: http://www.nwcopro.com OR my Developer Chat
    Any sufficiently advanced bug is indistinguishable from a feature.

  2. #2
    "Certified" Alphaholic
    Real Name
    Govindan Gandhi
    Join Date
    Aug 2008
    Location
    New York, NY
    Posts
    4,200

    Default Re: Documentation - what's the asterisk for?

    jim coltz wrote an article just for dates in this board, either search it under his name or together dates and his name or in the code section, you will find that article. that was, and is, an excellent contribution.
    if you cannot find it post back i will look for it.
    also there are many articles on the internet. since you are doing mostly web/mobile, you might want to get a book on javascript and they do talk about dates in many versions i went thru.
    thanks for reading

    gandhi

    version 11 3381 - 4096
    mysql backend
    http://www.alphawebprogramming.blogspot.com
    ggandhi344@gmail.com
    Skype:ggandhi344@gmail.com
    1 914 924 5171

  3. #3
    "Certified" Alphaholic Stan Mathews's Avatar
    Real Name
    Stan Mathews
    Join Date
    Apr 2000
    Location
    Bowling Green, KY
    Posts
    24,610

    Default Re: Documentation - what's the asterisk for?

    If memory serves, the asterisk indicates that the function employs lower level routines (C++ or something) and should be faster than similar alternatives.
    There can be only one.

  4. #4
    "Certified" Alphaholic CharlesParker's Avatar
    Real Name
    Charles Parker
    Join Date
    Dec 2012
    Location
    New Orleans, LA
    Posts
    1,572

    Default Re: Documentation - what's the asterisk for?

    NWCOPRO Nuisance Wildlife Control Software-My Application: http://www.nwcopro.com OR my Developer Chat
    Any sufficiently advanced bug is indistinguishable from a feature.

  5. #5
    "Certified" Alphaholic
    Real Name
    Govindan Gandhi
    Join Date
    Aug 2008
    Location
    New York, NY
    Posts
    4,200

    Default Re: Documentation - what's the asterisk for?

    Quote Originally Posted by CharlesParker View Post
    not correct, but stan is, as far as i know.
    thanks for reading

    gandhi

    version 11 3381 - 4096
    mysql backend
    http://www.alphawebprogramming.blogspot.com
    ggandhi344@gmail.com
    Skype:ggandhi344@gmail.com
    1 914 924 5171

  6. #6
    Alpha Software Employee Beta Spark's Avatar
    Real Name
    Sarah Mitchell
    Join Date
    Jul 2015
    Posts
    377

    Default Re: Documentation - what's the asterisk for?

    Quote Originally Posted by CharlesParker View Post
    On this page:
    https://www.alphasoftware.com/docume...ions/index.xml

    I see an asterisk as part of the function name, why is this? What does it mean? Also, some use case examples would be great on these - date and time math seems to be really troublesome for me!
    There's nothing particularly special about these functions. The asterisk is part of the function name and is used to avoid potential name collisions with user defined functions.

    Which date/time functions are you struggling with? We can add some examples. (Specifying specific functions will help us prioritize which ones to update first.)
    Last edited by Beta Spark; 10-11-2017 at 06:30 PM.
    Sarah Mitchell

    Looking for answers? Try our documentation.
    If you can't find something, let us know!

  7. #7
    "Certified" Alphaholic CharlesParker's Avatar
    Real Name
    Charles Parker
    Join Date
    Dec 2012
    Location
    New Orleans, LA
    Posts
    1,572

    Default Re: Documentation - what's the asterisk for?

    Thanks, Sarah! Specifically, I would like to see an example of the usage of add_minutes - I was actually surprised to hear that the asterisk is actually part of the name. David K and ghandi actually offered the help I needed (in another thread) and I am pretty sure I was barking up the wrong tree anyway when I found the add_minutes function. It would be great to see how one of these functions would be used in a UX or in a grid, not just 3 lines of code showing the syntax (although that is certainly helpful) I hope you do not take that wrong, the help system has been dramatically improved! You guys are doing a great job! It is obvious the AS team works it's butt off night and day - always moving forward.
    NWCOPRO Nuisance Wildlife Control Software-My Application: http://www.nwcopro.com OR my Developer Chat
    Any sufficiently advanced bug is indistinguishable from a feature.

  8. #8
    "Certified" Alphaholic
    Real Name
    Govindan Gandhi
    Join Date
    Aug 2008
    Location
    New York, NY
    Posts
    4,200

    Default Re: Documentation - what's the asterisk for?

    for what is worth,
    *add_minutes is an xbasic function, which will in turn require a call to the server. in my opinion that is not ideal or what you are looking for.
    get the minutes added via javascript or the trigger in the backend, you will be set to go.
    thanks for reading

    gandhi

    version 11 3381 - 4096
    mysql backend
    http://www.alphawebprogramming.blogspot.com
    ggandhi344@gmail.com
    Skype:ggandhi344@gmail.com
    1 914 924 5171

  9. #9
    Alpha Software Employee Beta Spark's Avatar
    Real Name
    Sarah Mitchell
    Join Date
    Jul 2015
    Posts
    377

    Default Re: Documentation - what's the asterisk for?

    Quote Originally Posted by CharlesParker View Post
    Thanks, Sarah! Specifically, I would like to see an example of the usage of add_minutes - I was actually surprised to hear that the asterisk is actually part of the name. David K and ghandi actually offered the help I needed (in another thread) and I am pretty sure I was barking up the wrong tree anyway when I found the add_minutes function. It would be great to see how one of these functions would be used in a UX or in a grid, not just 3 lines of code showing the syntax (although that is certainly helpful) I hope you do not take that wrong, the help system has been dramatically improved! You guys are doing a great job! It is obvious the AS team works it's butt off night and day - always moving forward.
    Will do! I'll see what I can put together.

    Also, if you're looking for a solution that would work on the client rather than the server, check out the UX getDateValue() method and the Date object addTime() method -- both of these are methods we created for use on the client to make it easier to do date math.
    Sarah Mitchell

    Looking for answers? Try our documentation.
    If you can't find something, let us know!

  10. #10
    "Certified" Alphaholic CharlesParker's Avatar
    Real Name
    Charles Parker
    Join Date
    Dec 2012
    Location
    New Orleans, LA
    Posts
    1,572

    Default Re: Documentation - what's the asterisk for?

    Yes, in the other thread David K pointed those out to me and were the solution that I was looking for.
    NWCOPRO Nuisance Wildlife Control Software-My Application: http://www.nwcopro.com OR my Developer Chat
    Any sufficiently advanced bug is indistinguishable from a feature.

  11. #11
    Alpha Software Employee Beta Spark's Avatar
    Real Name
    Sarah Mitchell
    Join Date
    Jul 2015
    Posts
    377

    Default Re: Documentation - what's the asterisk for?

    Quote Originally Posted by CharlesParker View Post
    Thanks, Sarah! Specifically, I would like to see an example of the usage of add_minutes - I was actually surprised to hear that the asterisk is actually part of the name. David K and ghandi actually offered the help I needed (in another thread) and I am pretty sure I was barking up the wrong tree anyway when I found the add_minutes function. It would be great to see how one of these functions would be used in a UX or in a grid, not just 3 lines of code showing the syntax (although that is certainly helpful) I hope you do not take that wrong, the help system has been dramatically improved! You guys are doing a great job! It is obvious the AS team works it's butt off night and day - always moving forward.
    I have added examples to all of the * date methods with an Ajax Callback example for the *add_minutes function. Let me know if this is helpful.
    Last edited by Beta Spark; 10-12-2017 at 11:57 AM. Reason: fixed incorrect link
    Sarah Mitchell

    Looking for answers? Try our documentation.
    If you can't find something, let us know!

  12. #12
    "Certified" Alphaholic CharlesParker's Avatar
    Real Name
    Charles Parker
    Join Date
    Dec 2012
    Location
    New Orleans, LA
    Posts
    1,572

    Default Re: Documentation - what's the asterisk for?

    WOW - excellent, thank you that is really great! Really clean, clear and with a short example like that it really makes it easier to understand. It seems to me that one of the hardest things to learn (and sometimes still is) for a new guy is WHEN and WHERE to use a function. Because you can use xbasic and javascript together and then not use xbasic in a client side javascript event (but can) it is often hard for me (and others) to determine usage when the example stops at syntax. I have seen several times on the forum where someone has xbasic mixed in with JS in a button click and using server side code in a client side event.
    I think that might be the key to creating better documentation - but anyways, getting back to your documentation efforts - this is perfect thanks!
    NWCOPRO Nuisance Wildlife Control Software-My Application: http://www.nwcopro.com OR my Developer Chat
    Any sufficiently advanced bug is indistinguishable from a feature.

  13. #13
    "Certified" Alphaholic
    Real Name
    David Kates
    Join Date
    Apr 2008
    Location
    Unionville, ON
    Posts
    6,065

    Default Re: Documentation - what's the asterisk for?

    Quote Originally Posted by CharlesParker View Post
    WOW - excellent, thank you that is really great! Really clean, clear and with a short example like that it really makes it easier to understand. It seems to me that one of the hardest things to learn (and sometimes still is) for a new guy is WHEN and WHERE to use a function. Because you can use xbasic and javascript together and then not use xbasic in a client side javascript event (but can) it is often hard for me (and others) to determine usage when the example stops at syntax. I have seen several times on the forum where someone has xbasic mixed in with JS in a button click and using server side code in a client side event.
    I think that might be the key to creating better documentation - but anyways, getting back to your documentation efforts - this is perfect thanks!
    Just to clarify for anyone stopping by to read this thread...

    You CANNOT use Xbasic and Javascript together
    You CANNOT use XBasic in a client side Javascript event
    You CANNOT mix Xbasic in with Javascript in a button click
    You CANNOT use server side code in a client side event

    I think you may not actually mean what you wrote as you wrote it... but the words are quite misleading. Essentially you wrote the same thing 4 times.

  14. #14
    "Certified" Alphaholic
    Real Name
    Govindan Gandhi
    Join Date
    Aug 2008
    Location
    New York, NY
    Posts
    4,200

    Default Re: Documentation - what's the asterisk for?

    Quote Originally Posted by Beta Spark View Post
    I have added examples to all of the * date methods with an Ajax Callback example for the *add_minutes function. Let me know if this is helpful.
    it will be nice to see in the documentation what version of alphfive needed to use any given function.
    thanks for reading

    gandhi

    version 11 3381 - 4096
    mysql backend
    http://www.alphawebprogramming.blogspot.com
    ggandhi344@gmail.com
    Skype:ggandhi344@gmail.com
    1 914 924 5171

  15. #15
    "Certified" Alphaholic kkfin's Avatar
    Real Name
    Kenneth
    Join Date
    Dec 2006
    Posts
    1,268

    Default Re: Documentation - what's the asterisk for?

    This is out of scope but what I have found interesting is that you can invoke xbasic function(s) saved in for example in CouchDB json.

    So you can write function(s) using json key value par syntax and then use a little trick to run it. Nice but dangerous.


    You CANNOT run Xbasic function directly from CouchDB json:)

  16. #16
    "Certified" Alphaholic CharlesParker's Avatar
    Real Name
    Charles Parker
    Join Date
    Dec 2012
    Location
    New Orleans, LA
    Posts
    1,572

    Default Re: Documentation - what's the asterisk for?

    I think you may not actually mean what you wrote as you wrote it... but the words are quite misleading. Essentially you wrote the same thing 4 times.
    lol, yep - I can't say I am 100% accurate in defining exactly what I was trying to say - but - and this is the interesting part, thare are blurred lines for many people coming into this, it takes some time to get a grasp on what's what. When you see an example such as has been added to the documentation you start to get a better understanding as to where this fits in. Like Gandhi, said, in a previous post/example I was better off with client-side. As a "noob" we don't know it.
    Good thread all around, always - learning and moving forward!
    NWCOPRO Nuisance Wildlife Control Software-My Application: http://www.nwcopro.com OR my Developer Chat
    Any sufficiently advanced bug is indistinguishable from a feature.

  17. #17
    Alpha Software Employee Beta Spark's Avatar
    Real Name
    Sarah Mitchell
    Join Date
    Jul 2015
    Posts
    377

    Default Re: Documentation - what's the asterisk for?

    Quote Originally Posted by GGandhi View Post
    it will be nice to see in the documentation what version of alphfive needed to use any given function.
    Like this? https://www.alphasoftware.com/docume...red%20function and https://www.alphasoftware.com/docume...eader%20method
    Sarah Mitchell

    Looking for answers? Try our documentation.
    If you can't find something, let us know!

  18. #18
    "Certified" Alphaholic
    Real Name
    Govindan Gandhi
    Join Date
    Aug 2008
    Location
    New York, NY
    Posts
    4,200

    Default Re: Documentation - what's the asterisk for?

    yes, very good. hopefully, in time, all the functions and methods will have something like that, meaning the minimum version needed to run that action.
    very good.
    thanks for reading

    gandhi

    version 11 3381 - 4096
    mysql backend
    http://www.alphawebprogramming.blogspot.com
    ggandhi344@gmail.com
    Skype:ggandhi344@gmail.com
    1 914 924 5171

Similar Threads

  1. Replies: 3
    Last Post: 10-29-2013, 04:52 AM
  2. V11 Documentation
    By David Priest in forum Alpha Five Version 11 - Desktop Applications
    Replies: 1
    Last Post: 04-22-2013, 08:20 PM
  3. Documentation again
    By JimDK in forum Application Server Version 10 - Web/Browser Applications
    Replies: 1
    Last Post: 12-01-2009, 01:33 PM
  4. New PDF Documentation
    By Edward Larrabee in forum Alpha Five Version 5
    Replies: 0
    Last Post: 10-21-2004, 06:34 AM
  5. A5 Documentation
    By Allen Palmer in forum Announcements
    Replies: 2
    Last Post: 03-27-2002, 06:56 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •