Alpha Software Mobile Development Tools:   Alpha Anywhere    |   Alpha TransForm subscribe to our YouTube Channel  Follow Us on LinkedIn  Follow Us on Twitter  Follow Us on Facebook

Announcement

Collapse

The Alpha Software Forum Participation Guidelines

The Alpha Software Forum is a free forum created for Alpha Software Developer Community to ask for help, exchange ideas, and share solutions. Alpha Software strives to create an environment where all members of the community can feel safe to participate. In order to ensure the Alpha Software Forum is a place where all feel welcome, forum participants are expected to behave as follows:
  • Be professional in your conduct
  • Be kind to others
  • Be constructive when giving feedback
  • Be open to new ideas and suggestions
  • Stay on topic


Be sure all comments and threads you post are respectful. Posts that contain any of the following content will be considered a violation of your agreement as a member of the Alpha Software Forum Community and will be moderated:
  • Spam.
  • Vulgar language.
  • Quotes from private conversations without permission, including pricing and other sales related discussions.
  • Personal attacks, insults, or subtle put-downs.
  • Harassment, bullying, threatening, mocking, shaming, or deriding anyone.
  • Sexist, racist, homophobic, transphobic, ableist, or otherwise discriminatory jokes and language.
  • Sexually explicit or violent material, links, or language.
  • Pirated, hacked, or copyright-infringing material.
  • Encouraging of others to engage in the above behaviors.


If a thread or post is found to contain any of the content outlined above, a moderator may choose to take one of the following actions:
  • Remove the Post or Thread - the content is removed from the forum.
  • Place the User in Moderation - all posts and new threads must be approved by a moderator before they are posted.
  • Temporarily Ban the User - user is banned from forum for a period of time.
  • Permanently Ban the User - user is permanently banned from the forum.


Moderators may also rename posts and threads if they are too generic or do not property reflect the content.

Moderators may move threads if they have been posted in the incorrect forum.

Threads/Posts questioning specific moderator decisions or actions (such as "why was a user banned?") are not allowed and will be removed.

The owners of Alpha Software Corporation (Forum Owner) reserve the right to remove, edit, move, or close any thread for any reason; or ban any forum member without notice, reason, or explanation.

Community members are encouraged to click the "Report Post" icon in the lower left of a given post if they feel the post is in violation of the rules. This will alert the Moderators to take a look.

Alpha Software Corporation may amend the guidelines from time to time and may also vary the procedures it sets out where appropriate in a particular case. Your agreement to comply with the guidelines will be deemed agreement to any changes to it.



Bonus TIPS for Successful Posting

Try a Search First
It is highly recommended that a Search be done on your topic before posting, as many questions have been answered in prior posts. As with any search engine, the shorter the search term, the more "hits" will be returned, but the more specific the search term is, the greater the relevance of those "hits". Searching for "table" might well return every message on the board while "tablesum" would greatly restrict the number of messages returned.

When you do post
First, make sure you are posting your question in the correct forum. For example, if you post an issue regarding Desktop applications on the Mobile & Browser Applications board , not only will your question not be seen by the appropriate audience, it may also be removed or relocated.

The more detail you provide about your problem or question, the more likely someone is to understand your request and be able to help. A sample database with a minimum of records (and its support files, zipped together) will make it much easier to diagnose issues with your application. Screen shots of error messages are especially helpful.

When explaining how to reproduce your problem, please be as detailed as possible. Describe every step, click-by-click and keypress-by-keypress. Otherwise when others try to duplicate your problem, they may do something slightly different and end up with different results.

A note about attachments
You may only attach one file to each message. Attachment file size is limited to 2MB. If you need to include several files, you may do so by zipping them into a single archive.

If you forgot to attach your files to your post, please do NOT create a new thread. Instead, reply to your original message and attach the file there.

When attaching screen shots, it is best to attach an image file (.BMP, .JPG, .GIF, .PNG, etc.) or a zip file of several images, as opposed to a Word document containing the screen shots. Because Word documents are prone to viruses, many message board users will not open your Word file, therefore limiting their ability to help you.

Similarly, if you are uploading a zipped archive, you should simply create a .ZIP file and not a self-extracting .EXE as many users will not run your EXE file.
See more
See less

custom toolbar

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    custom toolbar

    If I create my own toolbar and use the following:

    tbar = toolbar.open("My Own Toolbar")

    Where exactly would I put the above code so that my custom toolbar appears on the form? I thought I had read a post in the past that was similar to this but all my searches for toolbars did not return the thread I was looking for :(

    How do I save my custom toolbars so that I can use them in other applications? Is there a way to do this like with the code library for functions?
    Cheryl
    #1 Designs By Pagecrazy
    http://pagecrazy.com/

    #2
    RE: custom toolbar

    I'm not sure if this is what you are doing but if the form will always use the same toolbar, just set the toolbar for that form in the form properties.

    If the toolbar to be used depends on who is using it or some other "variable" then you will need to set it with xbasic but I've never had to do that so I'm not really sure how it's done - however, your thread lead me to do some testing so I will know in the future. Here's what I found:

    First, in the interest of time, I only tested from the OnActivate event.

    If you want to remove the system toolbar on a form, this seems to work:
    DIM tbp as P
    tbp = toolbar.get("form view")
    tbp.close()

    To add "MyToolbar" to a form (note that this says "add" - it does not replace an existing toolbar) I did this:
    toolbar.open("MyToolbar")

    And, of course, something similar to the first routine can be used to remove the custom toolbar - with the appropriate name change - if you want to replace it with a different toolbar.

    Cal Locklin
    www.aimsdc.net

    Comment


      #3
      RE: custom toolbar

      Hi to you both,

      I have the attached code on the in_init event of a menu form.

      You will observe that it has the effect of replacing the menu entered in form properties with another menu if the logon is a person with a system privilege.

      Don't get confused that both of the choices in the select_case are the same. That is temporary; remember that the default, non-sys, menu is set in the form's properties.

      Bill
      Bill Hanigsberg

      Comment


        #4
        RE: custom toolbar

        Thanks to both of you, I will play around with your suggestions and let you know what I end up with. May be a little while as I have a new project to work on.

        Consider that a warning, a new project means I will be posting more questions than answering again for a little while ***winks***
        Cheryl
        #1 Designs By Pagecrazy
        http://pagecrazy.com/

        Comment


          #5
          RE: custom toolbar

          Cheryl,

          Maybe I missed something. Did you create your custom toolbar in the CODE section of the control panel (New " Toolbar)? If you did, then you saved it with a name (MyToolbar)?

          On the form you attach the toolbar with the form properties tab.

          If I missed something, I apologize :). I attached a bmp showing how I have mine attached. You can attach the same one to multiple screens.

          Hope this helps,
          Jerry

          Comment


            #6
            RE: custom toolbar

            Hi Jerry,

            Yes to all of your questions. I already know how to attach my toolbar if it is in the code of the current application. What I am trying to accomplish is taking that toolbar and saving it in a code library like I do with my functions so that I can access it from all my applications and use and/or modify it in the new application if I need to.

            Thanks
            Cheryl

            I have not yet tried any of the other suggestions yet :(
            Cheryl
            #1 Designs By Pagecrazy
            http://pagecrazy.com/

            Comment


              #7
              RE: custom toolbar

              OK, this is what I ended up with. I opened my application that had the basic toolbar that I wanted to start with. I did a copy to new database and selected the new application that I am working in (thanks Jerry). I then opened my new application and the toolbar appeared in the code window so that I could modify it to fit my specific needs for that particular application.

              What I would really prefer is a toolbar library feature similar to the code library feature. That way I can keep all my custom toolbars, menus, functions, scripts, etc in one central location. What I am going to do since this is not available is create a dummy master database just for this purpose.

              Thanks to all for your suggestions and ideas.
              Cheryl
              #1 Designs By Pagecrazy
              http://pagecrazy.com/

              Comment


                #8
                RE: custom toolbar

                Hi again,

                I realize this is an old thread. I thought I had read elsewhere in the forum where there was an easier way to copy toolbars from one application to another.

                If there is an easier way than the way I used, any suggestions would be greatly appreciated. If not, perhaps I will add this to the new features wish list.

                Thanks
                Cheryl
                Cheryl
                #1 Designs By Pagecrazy
                http://pagecrazy.com/

                Comment


                  #9
                  RE: custom toolbar

                  Cheryl:
                  Since you are always out there helping everybody, I suppose everybody should try to return the favor once in a while.
                  Your observation that alpha does not have a library to store toolbars is correct, and maybe for a good reason. Actually, couple reasons:
                  1-How many toolbars you anticipate to build ??
                  Your work around of creating a dummy table is not necessary, for the following reason:
                  2-The custom toolbar is, in essence, a libarary of toolbars in and by itself.

                  What you need to do, instead of creating a table of all toolbars you anticpate to create (and since most likely those toolbars will have many icons in common), what you should do is create "The Mother of All Toolbars". One that contain ALL possible icons. That's your library. Then on each particular form, enable/disable the ones you like.

                  As to user-specific toolbars:
                  1-Bill suggestes a table to have toolbars specific to the user who logs in. That is one way and a legitimate way to do it and most liekly the most common way to do it.
                  2-But you could also take advantage of the condtions to enable/disable icons which is also built-in the custom toolbars.
                  Good Luck.
                  Gabe

                  Comment


                    #10
                    RE: custom toolbar

                    Hi Gabe,

                    Thanks for your suggestions. Although they are helpful for use within ONE application, it does not resolve my problem of being able to take my custom toolbar(s), copy it from one application, to another application.

                    I have been able to 'duplicate' the toolbar to the new location, but it would be so much easier if the toolbars and menus could be stored in a library like our custom scripts and functions.

                    I have a lot of scripts, functions, toolbars, etc that I have standardized so that I can use them in most applications that I work with. I of course am a 'lazy' programmer and prefer to not have to write my code more than once.

                    I will post this to the wish list. If there are specific reasons why a decision has been made to NOT allow something like this, then I am sure I will be told. Otherwise, maybe someday in the list of millions of wishes, this one will come true.

                    Thanks again for your suggestions.
                    Cheryl
                    Cheryl
                    #1 Designs By Pagecrazy
                    http://pagecrazy.com/

                    Comment


                      #11
                      RE: custom toolbar

                      I am not sure why you say that toolbars and menus cannot be stored in a library that is shared among many different databases. They can.

                      For example, open any database that you created. Go to file/database properties.

                      Go to the Libraries tab
                      attach c:\program files\a5v6\samples\alphasports.alb

                      now create a form for one of the tables in your app.
                      in the form properties, go to menu/toolbars.
                      set the toolbar for you app to "MainMenu" (this is a toolbar defined in alphasports).

                      it works fine!

                      Comment


                        #12
                        RE: custom toolbar

                        Selwyn,

                        Your solution is a great resource that I was not aware of, however, it gives me way to much. I followed the steps you provided and imported one of the application libraries that I had created several custom toolbars in.

                        Now I have every single custom script, function, toolbar, etc from that application which is not what I need. Now I would need to go through all the files on the code tab, delete those that I do not need and then still have to 'duplicate' the ones I do need in order to have it for specific use in the new application.

                        I would prefer to be able to right click like I do with the code library and select and choose the 2 or 3 toolbars that I want, just like I can with the scripts and functions.

                        Although the resource you just showed me would allow me to create my own master library of toolbars and menus like I do with my scripts and functions.

                        Thanks
                        Cheryl
                        Cheryl
                        #1 Designs By Pagecrazy
                        http://pagecrazy.com/

                        Comment


                          #13
                          RE: custom toolbar

                          Selwyn:
                          I think Cheryl was elluding a library that would be "specific" to store toolbars only so she could transport it from one app to the other as opposed to one that stores menus, toolbar etc.
                          That way if you need Only the custom toolbar, you could copy it to the new app instead of copying everything else along with it.
                          Gabe

                          Comment


                            #14
                            RE: custom toolbar

                            Obviously Cheryl is a much faster typist than I am. Sorry if my post seems reptitive to hers, I didn't read hers before postin mine !
                            Gabe

                            Comment


                              #15
                              RE: custom toolbar

                              Cheryl, don't go deleting what you don't need! You haven't imported the library, you've attached directly to it. Deleting anything here will delete it in the original database too.

                              -Lenny

                              Lenny Forziati
                              Vice President, Internet Products and Technical Services
                              Alpha Software Corporation

                              Comment

                              Working...
                              X