Archive

Author Archive

Finding a Specific Control

August 29th, 2011 5 comments

Real Studio is pretty easy to learn.  Navigation is pretty easy and switching between the layout and code editors is pretty straightforward for the most part.  There are times, however, where the simplicity of Real Studio fights you.

Take for example, this report that comes with the examples folder.  It has a number of layered controls (meaning the controls have a parent) and in this case, their are quite a few ReportLabel and ReportField controls on a ReportRectangle.  In the layout editor this isn’t a big deal because the layout is simple.  Click on any one of the controls and you can get its properties.

 

 

  However, once you get into the code editor, all you see is a list of controls, sorted by name.  There is absolutely no hierarchy that you can deduce from the list.  It’s a major headache for complex layouts, in my opinion.

In my ideal world I’d love the ability to right-click on the item in the code editor and select ‘reveal’ (or similar) and have the layout editor displayed with the control selected.  It would solve some headaches such as the occasional hiccup where Real Studio puts the child control outside of the visible region of the parent.  When that happens, you can no longer see it.  So  how does one ‘select’ the control to either move it, delete it, or otherwise edit it?

You can easily do the opposite case.  In the layout editor, right click on a control and use the “Edit Code” submenu to quickly get to an event in the code editor.  However, for some reason, I rarely use this command.

The contextual menu (i.e. right-click) in the layout editor provides some nifty commands that you might not be aware of.  The one we’re interested in, in this case, is the Select menu.

 

 

 

 

 

What the Select menu does, is give you a listing of all the controls, in their hierarchical, and alphabetical order.  So in this example from one of my current projects shows a relatively simple hierarchy with a GroupBox control (SSFrame6) hosting two canvas controls (cvsHusband, cvsWife) hosting DateControls, Labels, RadioButtons and Pushbuttons.

In some instances, this might be the only way that I could select one of the controls.  It’s easy enough to screw it up.  Make the canvas big enough to fit all the controls in it and then reposition it and resize it so that none of the other controls are visible.

Once this happens you’ll never ‘see’ the control in the layout editor but the code behind the controls might be firing anyway (for example if you have code in their open events) which might cause some issues.

While I’m here I’ll make a plea for some common sense naming conventions.  If you take a look at the RS example, GasReport.rbp above, you’ll notice that all the controls are using their default names.  At a glance you can’t tell what Field1 vs Field10 does.  This is one of those things that drives me crazy!

I see too many OPC (Other Peoples Code) projects every month to condone this behavior.  If I were to get this project to fix, the first thing I’d do is name the major controls (I might skip labels – but only if they’re not referenced in code) so when I see them in the code editor I can, from a glance, see what their intent is.

I know this is nit-picky, but I see it time and time again.  If you’ve subscribed to my Real Studio Video Training Series, you’ll note that I rarely leave the controls with their default name.  The few times I do I tend to apologize for breaking my own ‘rule’.  My thought behind this rule is that I’m not only coding for now, but for five years from now when I open the project again.  I don’t want to have to switch between the code and layout editors to figure out what a pushbutton does.  If it’s named properly I can tell its function.

Anyway, enough of the soapbox.  I hope you learned something.

Any tricks that you’ve discovered in the IDE?

 

Developer Referral Program

August 24th, 2011 6 comments

We’ve been Real Studio consultants for ten years now.  We also belong to the Real Studio Developer Referral Program.  We get a fair amount of consulting business from the referrals.  It’s probably safe to say that over 50% of our business is a direct result of the Referral Program.

We answer most posts that potential clients add at the Find a Developer Page and while we don’t get an answer from everyone we do talk to quite a few.  What amazes me is how few developers are responding to referrals.  A potential client told me today:

You were the first (and so far, the only) to reply.

This was a fairly straightforward project that was for a cross-platform app.  The client even knows what technologies they want to use.  How hard can that be?

The Developer Referral Program cost $495 for 12 months and $295 for 6 months.  This isn’t a lot of money (it used to be a lot more when it was bundled with priority support plans) and it can easily be made back on a single project.  If you’re looking for Real Studio development work, this is a good way to get into it.

What’s great about the Referral Program is that the people asking for developers already believe they need Real Studio.  There’s no selling them on the benefits of Real Studio – they’ve already decided on it!  Talk about shooting fish in a barrel.

Anyway, I just thought I’d share this with you.  Every Real Studio consultant I know (and I know more than a few) is busy.  There is enough work for more Real Studio consultants.

Malformed Header Error?

August 20th, 2011 3 comments

I know that some people are having problems getting R2 Web Edition web apps to run.  I was having the same problem on a few of the more complicated apps I’ve been working on and what made it frustrating was that locally, on my Mac, they ran fine in debug and in as regular web apps.  But on two separate Linux servers (one in CentOS and the other is unknown) they crashed.  I dug into the Error Logs on the servers and kept running across lines like this:

Malformed header from script. Bad header=App.Open

What was in my open event?  Well, I was connecting to the database and upon success opening  a web page and that’s it.  Simple, right?

I was also doing some logging and was calling a method called PrintAndLog which would append whatever string I passed in to a log file and it would send the same message to the console via the Print command.

After much tearing out of hair (and those that know me surely will recognize that I’ve done this a lot!) I commented out ALL the code in App.Open and ran it on the server.  It worked!  So I then started uncommenting code line by line.  Eventually I got to the PrintAndLog call and sure enough that was it.

I then did the same thing in the PrintAndLog method and discovered it was the very first line in the method:

print s

Crazy huh?  Comment out that line and it works again.  What makes it weird is that I’ve used this in multiple places AFTER app.open and it works fine.  So I can only conclude that it has something to do with the application initializing and that print isn’t recommended at that point in time.

Yeah, I agree, it’s a stretch but stranger things have happened. This has been reported <feedback://showreport?report_id=17388> with an example project (the project is private, sorry).  Oh, and this still happens in the R3 beta’s.

So hopefully this might help someone in a similar predicament.

Finally!

August 19th, 2011 6 comments

Real Software today announced in their monthly newsletter the public availability of a Web Edition web app that can be launched on their website.  The link is http://demos.realsoftware.com/cgi-bin/orders/orders.cgi and you get get the source code for the project as well.

This is a decent example of what Web Edition can do for you.  It’s a fairly vanilla application but it’s something to look at and kick the tires of, so to say.  It’s nice to see it finally up as it was exposed to the beta list for a while.

I’ve been using Web Edition for real world projects since last November.  I think if they had developed this app back in November it would be a much more stable and mature product than it has been.

I hope that this is just the first of many such web apps that showcase the product.  Your thoughts?

Lion is a Mixed Bag

August 18th, 2011 3 comments

I’ve been a Mac user since 1986 and have used a Mac consistently ever since despite many years as an electrical engineer (where DOS and Windows was the norm).  I think I’ve used every Mac operating system since System 5.  I’m also a developer.  I straddle the world of user and power user.  I’m not a newbie but yet I don’t consider myself a Unix power user either.

I’ve had Lion installed for about 3 weeks now.  There are some things I like about Lion and more that I don’t like.

Things That I Like About Lion

Versions:  Being able to see edits in time has already saved me some grief when it comes to editing documents in Pages.  I accidentally opened the wrong document (similar but not the same) for a course outline and started typing away.  I realized after about 30 minutes of editing that this was the wrong one and looked at the old versions and quickly reverted.  See below why I don’t like Auto Save though.

Airdrop:  It’s simple and to the point.  This is how file transfers between occasional machines should work.  It’s not quite as convenient for computers that are already on the network though as it you have to be running AirDrop and approve all transfers.  I did have a problem with two Lion computers transferring zero length files but I don’t know if it’s been fixed in the update that came out this week.

Mail:  The 3 pane interface works for me.  It also keeps track of my conversations and organizes them effectively and reduces the redundant information.  This should have been done a long time ago.

The Price:  At $29 a computer it’s cheap.  The fact that all your computers on your network (using the same Apple ID of course) can get it too is just icing on the cake.

iChat:  Conversations are now unified into a tabbed window rather than each conversation being in a separate window.  For video chats it’s using FaceTime whether you realize it or not.

Preview:  Being able to add a signature to a PDF document has caused me no end of grief in the past several years even though I have a utility to do it.  Now, I don’t have to worry about it.

Auto Correct:  I know some people are bagging on it, but for the most part it works for me.  It’s not perfect but it warns you, visually, when it makes a correction.

Things That Don’t Bug Me But I Don’t Care About Either:

Natural Scrolling:  It took me maybe two days to get used to it.  Sure, I still go the opposite direction at times – get over it – it’s just the flick of a finger.

Full Screen Apps:  Meh.  For the few times that I want the app to take over my entire screen it’s okay but this feature seems to be aimed at 13″ laptop users.

Things I Hate About Lion

The UI elements:  Disabled controls are gray.  Enabled controls are gray.  Sure, they’re different shades of gray, but really?  Is black such a bad thing?  I think this is my number one pet peeve in Lion.

Mail Enabled Buttons:

 

 

Mail Disabled Buttons:

 

 

Overlay Scrollbars:  Again, another UI element that I think should visible all the time on my big assed 27″ monitor.  There is a preferences setting for it, by the way, but it seems out of place and not like the rest of Mac OS X.

Resume (i.e. Auto Open):  I’ve tried this a few times but I hate it more than I like it.  What I really want is to set this PER application – not system wide.  I don’t want this on Text Edit but I DO want it on Pages.  I don’t want it on my database editor, but I do want it on my development software.

Auto Save:  The apps that are actively using it (Text Edit, Pages, Numbers, etc) I find that I really don’t like it.  Why?  Because I create temporary documents all the time and when I quit the app I want them gone.  Isn’t that what the Save Prompt is for?  This is in direct contrast to Versions above.

iCal:  Really, Apple?  Faux Leather?  Otherwise it’s functional.  The changes to how to create an event on your calendar uses natural language (like Lunch with Carol at 12 PM automatically adds it to the calendar with the appropriate time).

Hiding of Library Directories:  I understand why they did this – most people really shouldn’t be mucking around in Library folders – but it’s more hassle than it’s worth, in my opinion.  Getting into the preferences folder is pretty common (and that happens to be in the Libraries directory).  It’s relatively easy to work around, but now I have to figure out if my users are smart enough to figure it out for themselves or if I have to handhold them through that process too.

Things That I Find Useless:

Launchpad:  Played with it and found that I already have the apps organized in the way I want either in the doc or in Stacks on the right side of my dock.  I suspect that people coming from iOS love this feature.

Things That Are in Snow Leopard and Lion that I Love:

Mac App Store:  If you’re not using it yet you should.  This is the most convenient way to find and purchase apps for your Mac.  The fact that you can then install it on all machines in your house (using the same Apple ID) is VERY convenient.  No more hassling with serial numbers or if, for whatever reason, you need to install old apps again, the Mac App Store can install them all at one time.

Conclusion:

There’s a lot of other changes in Lion too.  I recommend taking a look at the 250+ features page at Apple at http://www.apple.com/macosx/whats-new/features.html.

I find myself torn between the past and the future.  I’m a long-time Mac user so I’m no newbie and perhaps that’s why I’m not thrilled with Lion.  Despite some big improvements I find most of the major changes to be a dumbing down of the OS for people that are coming from iOS.  That’s not necessarily a bad thing but I’m not sure it’s a good thing either.

What’s most disturbing is the horrible User Interface changes in Lion.  For a company that prides itself in making great UI I think most of it fails on multiple levels.  Visual cues are the first thing that need to be clear and obvious and for that they’ve failed in my book.

Should you upgrade?  If you find Leopard or Snow Leopard useful then keep using it – you’ll get Lion when you purchase a new computer.

What do you like or dislike in Lion?

EDIT:  Updated with images from Mail to show difference between enabled and disabled toolbar buttons.

Categories: Macintosh, Opinion Tags: , ,

The Plugins/Libraries We Use

August 9th, 2011 11 comments

We do a lot of projects every year.  Every project is different but we have a core set of third party controls and plugins we use on a regular basis.  Here’s our list.

Monkeybread Software  http://www.monkeybreadsoftware.de/realbasic/

I know a lot of people complain about the Monkeybread plugins but we find them to be most useful.  Time is money and chances are good that if there’s a system declare you might need they’ve already done it.  Plus, they are very responsive to bugs and changes to Real Studio.  They’ve been very proactive in developing Cocoa compatible plugins.

The Chart Director plugin is a wonderful charting tool.  It has a ton of features and is very fast.  We’ve used it on a number of projects now and we’ve been very happy with it.

Automatic Updater Kit:  This set of classes and utilities is must have for Mac and Windows apps.  On Mac OS X it uses Sparkle to do automatic app updates and on Windows you can set it to use an installer file.  We’ve automated this (using IDE scripts) to the point where we only need to run one command line function to finish everything (and that only because we haven’t automated the Inno Setup process yet).  We recently modified the code to do some data file updating as well.

Einhugur  http://www.einhugur.com/index.html

We use much of this suite as well.  Real Studio does not ship with Date and Time or Calendar controls.  The Einhugur set comes with nice versions of those as well as a wicked fast TreeView and StyleGrid controls.  They have a number of other libraries and controls that are very useful including their E-CryptIt plugin that offers many encryption, encoding and hashing techniques.  Einhugur has also been very proactive in developing Cocoa compatible plugins.

Formatted Text Control  http://www.truenorthsoftware.com/formattedtextcontrol/

If your app needs true RTF file support or need inline graphics then this is a must have tool for you.  This is a set of pure RB classes (unencrypted) so you can dig into the guts and make your own modifications (or fix a bug or two as we’ve done over the years).  This is good code to learn from as well.  They recently added masking which is a nice replacement for the crappy masking that Real Studio provides with the TextField control.

RSReport  http://www.rothsoft.ch/realbasic/rsreport/

If you need anything other than basic (and I mean REALLY basic) reporting the built-in reporting tool isn’t all that impressive.  We’ve moved almost everything over to RSReport.  It’s great because you control everything.  It’s awful because you control everything.  Reports take a little longer to design and get running but the drop-in report viewer and the export to PDF capabilities more than make up for it.  They do have a Report Designer component but I’ve never gotten it to work well in my own projects so I’ve not used it.  Their lack of support is a little disconcerting but so far I’ve been happy with it to take the risk.

eSellerate  http://www.esellerate.net/

We use the eSellerate plugin for our own products.  It handles licensing and registration and though they take a cut off the purchase they’ve been fairly proactive in updating their service over the years.  Their RB plugin has NOT been updated for Cocoa so we really have no idea what we’ll use if they don’t update it.

What are you using a lot that’s not in our list?

Review: FGThumbnailCanvas

August 7th, 2011 Comments off

I did a review of the Figa FGThumbnailCanvas on the ARBP site.  Interesting control and recommended if you have a need for a scrolling list of images.  I have a feeling this may make its way into a product of mine and into some client projects.

If you’d like your controls or libraries reviewed, please don’t hesitate to ask ARBP, or myself, or both, to review them.

Categories: ARBP, Opinion, REALbasic Tags: , ,

Web Edition Question

August 5th, 2011 4 comments

Real Studio Web Edition has been around for roughly 6 months and 4 (or it is 5?) general releases.  Does anyone find it disconcerting and disappointing that Real Software does not have a SINGLE web app running on their website?

For desktop apps they can point to the IDE itself as what you can do with the product.  Web Edition needs examples, working, on their website, that do something.  If they really want to get people to buy their product the really need to have working examples.

What say you?

Real World 2012

August 1st, 2011 13 comments

Real Software announced today the dates and location for the 2012 Real World event.  It will be held in Orlando Florida May 24-25.  I think it’s great news that the Real Software is bringing back Real World.  I’ve always enjoyed them and I highly recommend going to one if you’ve never been to one before.

Thoughts in no particular order:

  • I’m glad it’s not in Austin, TX again.  I like Austin, but there’s not much draw to come back year after year.  Orlando, FL is an obvious, “let’s take the family” location and should be a draw.  How much of a draw remains to be seen.
  • The early bird discount is $500 and then increases to $600 and finally to $700 for last minute bookings.  The pricing seems a little hefty, but then this is at a premier hotel rather than a hotel out by the airport.  It’s nice that early booking gets you a 30% discount coupon in the Real Studio Store.
  • Orlando has a ton of stuff to do:  Disney World, Epcot Center, Seaworld, Harry Potter World, Universal Studios, Kennedy Space Center (a short drive),  and much, much more.  The drawback is that none of it is cheap so be prepared to drop some cash to do those things.  But, as they say, this is a destination location so you come knowing that it’s going to cost you.
  • Does the location make that big of a difference?  It depends.  The two ARBP conferences were in non-destination locations which meant very few brought their families and that meant we were all happy with minimal accommodations.  We were all just happy to be in a room talking about Real Studio.
  • The May 24-25 dates are the Thursday and Friday before Memorial Day weekend which is the start of the summer holiday season in the United States.  Will people be willing to take their summer vacation early?  I don’t know.
  • Perhaps one of the bigger issues is what to do with the kids.  For many school districts school is still in session.  For my son his last day of sixth grade will be May 25.  The timing already limits its appeal for me and my family.
  • It’s cute they used one of my old quotes on their announcement page.  It’s from one of the previous Real Worlds.
  • No word yet, obviously, on speakers or tracks.  It’s many months away yet and I would suspect Real Software will announce a call for speakers.

I love the Real World events and normally I’d say it’s a no brainer but the timing is awful for my family.  What do you think of the announcement?  Does having it in a destination city appeal to you or not?  Would you bring the family?

Real Studio Download Thoughts

July 27th, 2011 3 comments

You can file this one in the “Bob was bored and had a wild/random thought” category.  :)

The Real Studio download package comes with several hundred example projects.  These examples range from very useful to downright useless (in my opinion) but they’re there for people to explore and use.  So in other words, the example may or may not be all that helpful depending upon your skill level.

So my question of the day is why are these part of the download package/installer and not available in a special section of the Real Software website?  It would save on download sizes and it would become a centralized location for Real Studio examples.  Ideally, anyone could contribute to this list.

When we started ARBP and added the Source Code Repository, this was the intention.  I wanted it to be the Planet Source Code of Real Studio projects.  The ARBP source code repository has over a hundred projects and gets a fair amount of traffic and downloads.  The drawback is that few people contributed to it and the older projects are really showing their age.  The other drawback is that it’s NOT Real Software and despite only needing an account to use it a lot of people shy away.

The leading argument against such a page on Real Software’s website are the Real Studio users themselves.  There is a tendency for Real Studio users to complain (loudly) when the examples don’t work.  They are justified, in my opinion, since examples in the download package should work with the version of Real Studio in the download package.  To me, if it’s in the download package it implies that it works implicitly with that version of Real Studio.  Unfortunately, that’s not how it works and sometimes leaves new users with a bad taste in their mouths.

A projects repository web page doesn’t have this problem as the person uploading the project sets the version of Real Studio it was created with and perhaps what operating system and adds some tags to it or something like that.  How cool would it be to upload the project file(s), have an RS web app scan it, pull out the keywords and make it part of a searchable system?  Of course it would allow other users to vote and leave comments.

I post a fair bit in the Real Software forums.  Often times I point to the relevant information the poster needs in the Real Software wiki or to various 3rd party developer websites.  I could see a projects page doing something similar and allow me to link to the project that would help the poster out.

Another thought would be to make this a Web Edition application since essentially we’re talking about a web app that’s a front end to a database.  Perfect place for a WE we app in my opinion.

Could ARBP do this?  Of course they could and it was discussed, in-depth, at the Atlanta conference in March.  They could do it – I have no doubt since they have some pretty smart people in ARBP – I just don’t think ARBP should be the one doing it.  I’m arguing that Real Software is a better and more logical entity to host this thing.

The Real Studio community isn’t as large as Visual Basic – that’s just simple math.  You could argue that a mere percentage or two of users would ever contribute to the projects page and that probably true.  However, assuming that Real Software sticks around for a few more decades, I would argue that one contribution a month is more than what we have now and more examples are better.

What say you?