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

Using ActiveX controls

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

  • Using ActiveX controls

    Hi,

    We have a requirement to allow the user to draw simple diagrams within a form, I suppose this cannot be achieved using the default a5 controls, so I'm contemplating on using a 3rd party ActiveX control, so just wanted to collect the experts views on this to help me proceed. Many thanks in advance for your time on this.

    Cheers

    Vasan

  • #2
    Re: Using ActiveX controls

    Vasan,

    You have asked a question about the Achilles heel of this product.

    Alpha Five does not, and apparently will not, publish a list of compatible ActiveX controls.

    I have had very mixed results with third party controls from:
    1. Dev Express
    2. Code jock
    3. DBI tech
    4. Infragistics

    Big problem number 1: No one offers examples written in Alpha Five XBasic and translating VBA to XBasic is not as straightforward as it should be.
    XBasic has syntax twists and turns that you just have to struggle with. I've worked with expert VB coders who simply threw up their hands and said you need to go back Visual Studio instead.

    Big problem number 2: Don't assume that Alpha Five allows all properties or methods to be used for a given control. Some of them work, and others do not.

    Big problem number 3: Many modern controls enable drag and dropping capabilities that Alpha Five apparently can not handle. Any kind of drawing control would likely use dragging and dropping so this may be a real problem.

    Observation 4: Alpha Five is superior to FileMaker in that the latter can not use ActiveX controls at all, and their native controls are inferior to Alpha's Controls. But when Alpha Five notes this in their marketing grid, it's a little like picking a fight with your sister. They don't mention that controls that work out of the box with Microsoft Access require lots of tinkering to get to work with Alpha Five, if they work at all. A new user, like me a year ago, assumed while this is the greatest thing since sliced bread -- all kinds of neat built in functionality and what isn't included can be supplemented with third party controls. Now certain amount of disillusonment has set in.

    I am about to submit a request to Alpha on a paid services basis to convert the EXTREMELY simple Microsoft Access example for Codejock's CalendarPro activeX control. I've spent several months on this and still haven't got it to work. Yet when used with Microsoft Access, you can easily reschedule an appointment by dragging it from one time slot to another, just as you do in Outlook.

    I am doing this on a Pro Bono basis. If Alpha accept the challenge, I'll gladly post the result on the forum because there are probably more than a few developers out there who would like to incorporate an Outlook style calendar in their application.

    Bob McGaffic
    Pittsburgh, PA
    Last edited by rmcgaffic; 04-09-2009, 10:21 AM.

    Comment


    • #3
      Re: Using ActiveX controls

      Alpha does have some Draw capabilities....I will find a few links that describe them.

      This link from the help file should give you some idea of what is possible or not.

      http://support.alphasoftware.com/alp..._Functions.htm
      Mike
      __________________________________________
      It is only when we forget all our learning that we begin to know.
      It's not what you look at that matters, it's what you see.
      Henry David Thoreau
      __________________________________________



      Comment


      • #4
        Re: Using ActiveX controls

        Mike's link shows how it is possible to create a bitmap using XBasic code.

        But this may be way too much to expect of a user who is expecting Microsoft Paint style ease of use.

        Bob McGaffic
        Pittsburgh

        Comment


        • #5
          Re: Using ActiveX controls

          Hi Bob,

          Originally posted by rmcgaffic View Post
          Alpha Five does not, and apparently will not, publish a list of compatible ActiveX controls.
          I don't think anyone could. It depends on what controls you use, which methods and what type of properties and parameters, as to whether it's compatible. E.g. passing variants I believe is next to impossible. If you need to use those, find another Active X.

          Originally posted by rmcgaffic View Post
          Big problem number 1: No one offers examples written in Alpha Five XBasic and translating VBA to XBasic is not as straightforward as it should be.
          Not quite true, I myself, as well as Marcel and others have listed examples
          Translating could be easier, but unfortunately, it's kind of Apples & Oranges between VBA and XBasic

          Frankly, I feel many of the Windows API's and other Active X's are also poorly documented and could be clearer in their usage.
          Regards,

          Ira J. Perlow
          Computer Systems Design


          CSDA A5 Products
          New - Free CSDA DiagInfo - v1.39, 30 Apr 2013
          CSDA Barcode Functions

          CSDA Code Utility
          CSDA Screen Capture


          Comment


          • #6
            Re: Using ActiveX controls

            I've been playing with this for months. I always get stopped at some point... either, drawing and saving, rotating, etc. This stuff is not easy. There is the OLE Browser which exposes Activex event, properties etc.

            The examples in A5 always show working with xdialog. Nothing that show how to work with an image, draw on it, save it, re-display it... on a form.

            I've had some luck with Pegasus Software controls -ImagXpress and THB Components - THBImage. They almost do what I want but not quite.

            I need to test ImagXpress under the runtime so I'll put together a small app and, it if works, I'll post it here, and the dev stuff to show what I'm doing.

            Pegasus and THB are both good... I've used them under VB before. ImagXpress is really fast at displaying images. I can't use the Image Reference Control in A5 - it's just too slow.

            At one time they were royalty free, but I think that's changed now - check them out anyway - seems ImagXpress has priced themselves out - at least for me. I have an older version that does not require runtime licensing costs so I'm trying to use that.

            THB has a process called Regions or Vectors that allows drawing on a displayed image in your form. I've finally figured that one out but saving the image via A5 changes some of it's size properties so I'm not sure that it's any good.

            I'm still looking for a good, seemless way to do displaying and drawing and rotating and saving, but haven't found one yet.

            http://www.accusoft.com/imagxpress.htm

            http://www.thbcomponents.com/site/mo...ducts&op=index

            Comment


            • #7
              Re: Using ActiveX controls

              Thanks Bob, Mike, Ira & David.

              I'm bit confused but overall it appears from the discussion that ActiveX controls indeed is a tricky affair with Alpha Five. It appears from David's comments that he is still unable to make any of the image activex controls to work completely in Alpha Five, this certainly is not good thing for Alpha, considering its other big strength.

              Anyway thanks for all your time and I have decided to inform my client that integrating a image drawing facility may be a tricky affair, will take his inputs and take it from there!!

              Cheers

              Vasan

              Comment


              • #8
                Re: Using ActiveX controls

                Just to be fair, I can get the controls to work under A5. I have to make concessions at times but they do work. I'm working on a sample app and will post that soon.

                Comment


                • #9
                  Re: Using ActiveX controls

                  Attached is a sample database demonstrating the use of an Activex control for loading and drawing on an image. I'm using ImagXpress Version 5.

                  If you want to have a look, unzip it into an empty folder and then you'll have to register the control - imagxpr5.dll - using regsvr32.exe. This is the only dll you'll need to register.

                  It's just simple... drawing text and a circle and rotating.

                  The Save Rotate button overwrites the image.
                  The text and cirlce buttons save the image with a "1" appended to the filename.

                  There's lots more you can do with this control... draw arcs, lines, points, curves, fill areas, rectangles, etc.

                  Comment


                  • #10
                    Re: Using ActiveX controls

                    OK, I'm not an Alpha employee so I can't speak for Alpha. However, in my experience they are committed to make Alpha Five work with all ActiveX controls. I have used several ActiveX controls without problems and whenever I've found and documented a problem, they have debugged the issue and come out promptly with a fix. If you have an ActiveX control that works with Access or VB and doesn't work with Alpha Five, and can document it, then you should report it as a bug and, if past experience is a guide, they will correct it within a few days. No one likes bad news but I have found that the Alpha Five development team is genuinely appreciative whenever someone provides them with a reproducible bug.

                    Comment


                    • #11
                      Re: Using ActiveX controls

                      Thanks a heap David, i just downloaded the sample app and it works like a charm!! Shall be exploring it in detail in the comming days. Thanks again!!

                      Vasan

                      Comment


                      • #12
                        Re: Using ActiveX controls

                        Peter,

                        Thanks for your guidance. I am glad to hear that if an ActiveX control will work with Microsoft Access, then it should work with Alpha Five, and that Alpha Software is comitted to achieving this goal.

                        As you may know, FMS is a major Access ActiveX control shop. They have just released their 2007 Total Access Components, which includes a splitter control for desktop forms. It works simply and beautifully on Access forms right out of the box, no coding, no property setting, etc.

                        In my opinion, Alpha needs a simple splitter that can be placed on a desktop form. I have absolutely no interest in learning the intracies of XDialog, and why should I? Access doesn't require code to make splitting work, and I feel Alpha should not either.

                        Following your suggestion, I am submitting a bug report tomorrow to Alpha Five because this same control is dead in water when used with A5V9.

                        I'll keep you posted on their progress.

                        Bob McGaffic
                        Pittsburgh

                        Here's the link and a short description. Click on the link to see an animation of how it works.

                        http://www.fmsinc.com/products/compo...r/splitter.htm

                        Total Access Components Tour: Splitter
                        The splitter control provides automatic resizing of controls on your form. If the Orientation property is set to horizontal, the control resizes any controls that lie to the top or bottom. If the Orientation property is set to vertical, the control resizes any controls that lie to the left or right.

                        Using the Splitter Control
                        First, place the splitter control on your form. Then, set the Orientation property to either horizontal or vertical. This controls the direction in which you can drag the splitter. Finally, position the splitter control between the other form controls you wish to resize

                        Comment


                        • #13
                          Re: Using ActiveX controls

                          Bob,
                          That's not really a fair example. The company states that their controls are ActiveX custom controls designed specifically for Microsoft Access. That means they won't work with Visual Basic either, or Visual Studio, or other Microsoft products. That's not the kind of ActiveX component that I believe Alpha can or should be aiming to be compatible with; the only way to achieve compatibility with that control would be to become a version of Access, since the developers of the control are specifically hooking into Access and only Access.

                          Comment


                          • #14
                            Re: Using ActiveX controls

                            Hey Bob,

                            FMS controls are built specifically for Access. To be fair to Activex controls you need to pick one aimed at a broader market.

                            I'm not sure I understand what you mean by the splitter control and and Xdialog - there's not really any relationship between these concepts.. is there? Isn't Xdialog a scripting language that will produce forms, popups etc? I suppose it might be nice to have a splitter type control in the toolbox but all the years I've worked with Access and FMS I didn't really use it. I haven't tried to resize a form in A5 yet, but nothing I've ever tried would ever resize an Access form nicely... VB yes, Access No.

                            In using ActiveX controls in A5 you'll need to, at times, interpret what is needed and how events are called - it's not too bad but not as apparent at times as Access or VB (really the same thing regarding the coding language). In truth, you become adept at reading code in a language so that reading anything else is tough.

                            For example... in VB, using ImagXpress, here's how to draw some text... the calls are virtually the same.

                            In VB...
                            Dim BLACK As Long
                            Dim RED As Long

                            In A5...
                            Dim c1 as colordefinition
                            Dim c2 as colordefinition
                            Dim c3 as colordefinition

                            c1.name = "green"
                            c2.name = "red"
                            c3.name = "black"

                            In VB...
                            ' 1. Load an Image
                            Xpress1.filename = App.Path & "\..\..\Media\pic1.bmp"

                            In A5...
                            strImg = ui_get_file("Select Image(s)","JPG(*.jpg)|BMP(*.bmp)|Tiff(*.tiff)","","x")
                            :frmAXTest:activex1.activex.FileName = strImg

                            In VB...
                            ' 2. We use a invisible XpressPRO control to Create a solid black
                            ' image. We then annotate the image with a red date and time.
                            BLACK = RGB(0, 0, 0)
                            RED = RGB(255, 0, 0)
                            XpressHidden.CreateDib 140, 15, 8, BLACK
                            XpressHidden.DrawText 0, 0, Date & " " & Time, RED
                            DoEvents

                            In A5...
                            :frmAXTest:ixhidden.activex.CreateDib(ImgW, ImgH, 8, c1.RGB_Value)
                            :frmAXTest:ixhidden.activex.DrawCircle(drawx, drawy, 100, c3.RGB_Value)

                            In VB...
                            ' 3. Area sets up the position of the annotation on the image. Merge
                            ' does a transparent merging of the image. Note, BLACK is the
                            ' transparent color.
                            Xpress1.Area True, Xpress1.IWidth - 140, 5, 140, 15
                            Xpress1.Merge True, 0, 0, True, BLACK
                            Xpress1.Picture = XpressHidden.Picture
                            DoEvents

                            In A5...
                            :frmAXTest:activex1.activex.area(.t., 0, 0, ImgW, ImgH)
                            :frmAXTest:activex1.activex.Merge(.t., 0, 0, .t., c1.RGB_Value)
                            :frmAXTest:activex1.activex.picture = :frmAXTest:IXHidden.activex.picture

                            In VB...
                            ' 4. Reset our area and Merge
                            Xpress1.Area False
                            Xpress1.Merge False
                            DoEvents

                            In A5...
                            :frmAXTest:activex1.activex.area(.f.)
                            :frmAXTest:activex1.activex.Merge(.f.)

                            In VB...
                            ' 5. The Annotation has been merged with the original image.
                            ' Now we'll save it.
                            Xpress1.SaveFileName = App.Path & "\..\..\Media\test.bmp"
                            Xpress1.SaveFile
                            DoEvents

                            In A5...
                            :frmAXTest:activex1.activex.SaveFileName = Fullname
                            :frmAXTest:activex1.activex.SaveFile()

                            In Vb...
                            ' 6. Load the annotated image back in to see the results
                            Xpress1.filename = App.Path & "\..\..\Media\test.bmp"

                            In A5...
                            :frmAXTest:activex1.activex.filename = Fullname


                            I don't know if you'll want to take to the time to go through each line but, you'll see they are not really different - they couldn't be actually or the controls wouldn't work. The documentation for the control is so important, and examples are very helpful, even though they're usually written for VB. The code above is a bit different between VB and A5 because I'm doing a bit more in A5, and drawing a cirle, but essentally the ideas are the same.

                            Comment


                            • #15
                              Re: Using ActiveX controls

                              David,

                              Thanks for your very detail instructions on the conversion of VB to ActiveX.

                              I generally have had no problems setting an ActiveX control's properties.
                              My problems are with events.

                              For example, double clicking on CodeJock's Xtreme Calendar Pro to display a message box "The double click event works". Alpha Five does not produce and error -- it just doesn't do anything.

                              When you mentioned that FMS splitter was meant for Access, why would it not work with Alpha Five? It is an ActiveX control.

                              Several forum members have asked why would you ever want to use a splitter control? Or one member has been developing applicaitons for 15 years and has never saw the need to use one?

                              I would like to develop an application that looks professional and not home made. I am interested in two subject areas (customer relationship management and career management) and I've got to tell you that almost every competitive application I look at is using splitters.

                              For example:
                              Intuit Quicken: List of accounts
                              Frontrange Goldmine: List of tasks
                              Act contact manager: List of tasks
                              Commence CRM: List of tasks
                              Centerbase CRM: Item explorer
                              Job Tabs job search software: List of resumes
                              Perfect job search: List of tasks
                              Microsoft Outlook: List of tasks

                              All of these applications allows the List on the left of the screen to be widened and shortened by the user. This is much more useful than a horizontal splitter at the bottom of the list.

                              So what I am trying to do is hardly new or revolutionary. As my examples illustrate, splitter controls are mainline. I am beginning to realize that most Alpha developers are not trying to create applications with this degree of polish and I'm OK with that. But the issue is not the design of my form, but whether Alpha Five can work with commercial activeX controls.

                              I'll look at other splitter bars this week at your recommendation. I plan try at least three that are VB compatible. If I can't get one of them to work, am going to submit all of them plus the FMS splitter to Alpha as a bug.

                              Bob McGaffic
                              Pittsburgh

                              Comment

                              Working...
                              X