Naming a new procedure

This topic was aired and possibly resolved a long time back but I’m obliged to revive it.

A new procedure name defaults to “Procedure_A” and, if you want a different name, it’s necessary to click in the name box, type a new name and close the Properties Pane. I’d be amazed if any user would want the default names other than very rarely.

I’d really like to create a new procedure, type its name, hit Return and start typing code - just like Panorama 6 did. If the current system is here to stay, could we maybe have the option (in a fully-developed Preferences panel) to do it the old way?

Do any other users find the current method a drag?

I believe the way Panorama X works is much more “Mac” like – with no modal dialog.

Personally, while I rarely use the default name long term, it’s very common for me to create a new procedure and just start typing code. I can worry about the name later. And sometimes the procedure is a throwaway that never gets a proper name. In Panorama 6, having to come up with a name immediately was often annoying, in my opinion. Of course, I’m biased, but honestly I still am a bit thrilled every time I create a new procedure and can just start right in with coding, even after several years of doing it.

You can certainly create your own procedure in the Action menu to work the way you want. Of course, you’d have to add it to every database, which is a bit of a bummer.

1 Like

I can identify with both of those statements.

Often enough I found myself pausing to think of a name, recognizing that I might have to live with it for a while, when I really wanted to paste or start coding. And yes, throwaways are very common when just tryng to figure something out or clean up some data. I’ve had a lot of names that were just a matter of which keys my fingers could find first so a name was technically entered and I could move ahead.

FWIW, I’ll throw in my 2¢

Change is rarely welcomed. The way things have always worked is usually safe. Sometimes improvements will not be seen as such by those that have developed ways to make use of what may have been ‘inferior’.

Personally, I too have come to appreciate that Panorama made me stop and think before I just started coding. That bit of hesitation sometimes allowed me to recognize that I already had some other code elsewhere that would work with minor modifications. Having to take a moment to come up with an appropriate name was all that it took to make me slow down and think. And usually I accomplish better things when I think instead of just doing.

As for the ‘default’ name, it is only of value for throwaway code. My preference is to write code that has value and can stand the test of time. Fewer procedures, better design is my goal. If I do need and want a throwaway, I can make that decision to name my procedure Junk or A as they both later are easily identified as something that was meant to be thrown away rather than something that I just forgot to rename from the default. I’ll quickly toss something called Junk but I’ll take time to examine Procedure_A to figure out what I meant when I wrote it. Was it junk or forgetting to rename.

Robert Ameeti

I can make that decision to name my procedure Junk or A

Yep, I’ve done that many time also. But then what if Junk or A is already taken? Now I have to think more about what junk name is available, when what I really want to think about is the code I am about to write.


To me however, the key point is that in most programs these days when you create a new document it’s called “Untitled 1”, “Untitled 2”, etc. Then you give the document a name when you save. I feel that this is the same situation, and that users from the general Mac community will be very comfortable with this. There are a few programs that prompt for a name right when you create a new document (Xcode is one), but I think that is definitely the exception rather than the rule.

I think it would be ok if there was a preference that would put the insertion point in the procedure name to start, instead of the code. So you could just start typing the name. However, this would be a pretty low priority for me to work on.

1 Like

But Procedure_A is NEVER the best choice for a procedure.

And this is similarly true in that ‘untitled folder’ is never the best choice but apparently for the average user, it is often a desired choice. My clients seem to like that name as I often find 'untitled folder 2, or ‘untitled folder 3’ on their desktops. And I am then taken to open each one to determine if there is anything in them and to then later rename them.

Interesting in that Apple has taken to have Xcode not do what is typically done. Perhaps they view their coders as above average intelligence and perhaps give them an opportunity to think first, code second.

Robert Ameeti

I think Xcode does it because they need the name right away to put into the project file. Also, when you create a new file in many cases you are really creating a twin set of files – the source file and the matching header file (this depends on the language, but is true for C, C++ and Objective-C). You have to use a special command later to change the name, in fact to rename an Objective-C file you have to select the class name in the source code, right click, then choose Refactor>Rename from the popup menu. Then it goes thru a whole fixup process on the project to do the rename. So I think Xcode is not a template for “how to do it” in this case.