ChadSmiley Blog Things about family, life, coding, and more

30Aug/052

Purple Thumbs

I have heard that people are green thumbs and just the other day I heard of black thumbs. Tonight I was purple thumbs!!! I successfully canned my first beets from the garden. The test of success is when we start eating them, I sure hope it was worth the work.

Filed under: Family 2 Comments
29Aug/050

Proverbs 29:11

A fool vents all his feelings,
But a wise man holds them back.
Tagged as: No Comments
26Aug/053

Dynamic Domino Web Form Design

Some Domino applications have many forms that basically have the same information with some different fields. These forms have no logic, but are used to capture data. I am considering using Mike’s Submitting Web Forms without Domino Fields concept and creating a dynamic form for the web. This would reduce development time and greatly reduce testing.


There would be three different forms and one agent:

  • The agent would read the post back and create/update the document with the field values
  • Basic web form shell - would contain the style sheets and the agents for saving and lookups to determine the fields. It would contain a table with two columns when rendered, the first column would be the field description and the second would be the value.
  • Form definition - would define the title and the dynamic form alias.
  • Field form - Defines the fields that appear on the form. Here is the list of the fields and a brief description
Form Multi-value selection of the forms that the field would appear on
Order A number field that would determine what order the field would appear in
Enabled Yes/No
Description Shown in the first column of the table
Name Name used to store the value on the Notes document
Visible Yes/No
Editable Yes/No
Default Value If editable, Use Formula language to determine value
Computed Value If not editable, Use Formula language to determine value
Type Type of field: drop down, list box, check box, radio button, Text, number, Date, Multi-line text
Type Attributes
HTML attributes
Style, width, rows …
Show calendar selector
Yes/No - Shows the calendar icon next to the field (Date Only)
Columns
The number of columns displayed ( check box, radio button)
Lookup Only available for drop down, list box, check box, radio button
Reference Lookup Name
The name of the reference lookup (See:http://www.chadsmiley.com/ReferenceLookup for more detail) for more detail)
View
Name of the view
Filter
For Lookups the value to limit the results (Formula allowed)
Return Column/Field Name
The value to return
Return Mapping
The field to set when result is returned (Formula allowed)
Format (Regular Expressions) Used for values like numbers, and dates
Format Message Message when value does not match expression, this would be used on the blur of the field
Validate Used for values like numbers, and dates
Validate Message Message when value does not match expression, when trying to submit
Goto Field Yes/No
Goto Field Name If validation failed this would be used to set the focus of the field that failed


The Form field would now point at the basic web shell form but there would be a second field maybe called FormDynamic that would be used to look up the dynamic form and field information. When composing a new form the URL would look as follows which would load the Team defined fields:
SomeDatabase.nsf?DynamicFormShell?OpenForm&DynamicForm=Team


I would greatly appreciate any feedback/comments on this initial design.

18Aug/050

Start LotusScript.doc from Designer

I have been looking for consitant way to document my LotusScript for a long time. So when LotusScript.doc was available in beta form I had to take a look. Here is some of the feedback that has been recieved. I now have one more improvement/enhancement I would like to see, which is to start LotusScript.doc from the database I want to document.

This idea started with Quick Elementer 2.0 by Alain H Romedenne. It was implemented in Quick Elementer 2.2.0. I then took this same idea and Using Version Numbers to Manage Database Designs

server := ""; database := "lsdoc_beta.nsf" ;
FromDBTitle := @DbTitle + "|" + @Implode( @DbName ; "!!" );
@StatusBar( "LotusScript.doc for : " + @Left( FromDBTitle ; "|" )) ;
@If( 
@Text( @DbLookup( "" : "NoCache" ; Server : database ; "Designer Launch"; @RightBack( FromDBTitle ; "|" ) ; 1 ) ) = @RightBack( FromDBTitle ; "|" ); @Return( @Command( [FileOpenDatabase]; server : database ; "Designer Launch" ; @RightBack( FromDBTitle ; "|" ) ; 
false ; true ) : @Command([ToolsRunMacro]; "(ACTION - Build LotusScript.doc for selected configuration)" ) ) ; "" ); 
@Command([Compose]; server : database ; "lsdoc_config" ) ; 
@UpdateFormulaContext;
 FIELD Title := @Left( FromDBTitle ; "|" ) ;
FIELD Server := @Left( @RightBack( FromDBTitle ; "|" ) ; "!!" );
FIELD FilePath := @RightBack( @RightBack( FromDBTitle ; "|" ) ; "!!" );
@Command([ViewRefreshFields]);
@UpdateFormulaContext;
@Command([FileSave] );
@Command([ToolsRunMacro]; "(ACTION - Build LotusScript.doc for selected configuration)");
@Command([FileCloseWindow])

I would not typically combine the database title with the server and file path but based on yesterday's post I had no choice.

One other twist that came to mind while writing this is taking a subset (basicly removing the runing of the agent) of this code and create an option to edit the LotusScript.doc configuration document from anywhere.

Code formatted using Format Formula as HTML

17Aug/050

@UpdateFormulaContext and @Command([Compose])

I found some interesting results using the @UpdateFormulaContext and the Compose command. It looks likes the tempary variables are actually pointers. Notice the difference (shown below) when the database information is stored in the variable instead of a string.

FromTitle := @DbTitle; 
 FromServerPath := @DbName ; 
 FromDB := @DbTitle + " | " + @Implode( @DbName ; "!!" ); 
 
 @StatusBar( "From title " + FromTitle ); 
 @StatusBar( "From path " + @Implode( FromServerPath ; "!!" ) ); 
 @StatusBar( "From DB " + FromDB ); 
 
 @StatusBar( "Before compose "  ); 
 @Command( [Compose] ;"" : "names.nsf" ; "Person"  ); 
 
 @StatusBar( "After compose "  ); 
 @StatusBar( "After compose From title " + FromTitle ); 
 @StatusBar( "After compose From path " + @Implode( FromServerPath ; "!!" ) ); 
 @StatusBar( "After compose From DB " + FromDB ); 
 
 @UpdateFormulaContext; 
 @StatusBar( "After Update Formula Context "  ); 
 @StatusBar( "After Update Formula Context From title " + FromTitle ); 
 @StatusBar( "After Update Formula Context From path " + @Implode( FromServerPath ; "!!" ) ); 
 @StatusBar( "After Update Formula Context From DB " + FromDB ); 
 
 @StatusBar( "Names title " + @DbTitle ); 
 @StatusBar( "Names path " + @Implode( @DbName ; "!!" ) ); 
 @StatusBar( "Names DB " + @DbTitle + " | " + @Implode( @DbName ; "!!" ) );

Here are the results:
From title Some Database
From path !!somedb.nsf
From DB Some Database | !!somedb.nsf
Before compose
After compose
After compose From title Some Database
After compose From path !!somedb.nsf
After compose From DB Some Database | !!somedb.nsf
After Update Formula Context
After Update Formula Context From title Someone's Address Book
After Update Formula Context From path !!names.nsf
After Update Formula Context From DB Some Database | !!somedb.nsf
Names title Someone's Address Book
Names path !!names.nsf
Names Someone's Address Book | !!names.nsf

Code formatted using Format Formula as HTML

Tagged as: No Comments
16Aug/053

Set Template Version without browsing

Chris listened to my first suggestion to be able to launch the database from designer so templates would be able to be selected. I still did not like having to open Chis' *Set Template Version* database every time, nothing against your design Chris.

As I started working with this more I realized users of Quick Elementer had the same type of request. Which is to be able to access the application using the currently selected template instead of having to browse. The code below will all you to set the Template Version based on the currently selected template.

Here is another Tool that I have I have added to the Tools menu in Designer next to Quick Elementer and Quick Elementer Code.

server := "";
database := "TemplateVersion.nsf" ;
 
TemplateVersion := @DbTitle + "|" + @Implode( @DbName ; "!!" ) ;
 
@UpdateFormulaContext;
@StatusBar( "Set template version for " + @Left( TemplateVersion ; "|" ) );
@Command([FileOpenDatabase] ;server : database ; "" ; "" ; @True ; @True ) ;
@UpdateFormulaContext;
 
@Command([ViewRefreshFields]);
 
FIELD RecentFilesTX := @Unique( RecentFilesTX : TemplateVersion );
 
@Command([ViewRefreshFields]);
 
FIELD SelectFileTX := @RightBack( TemplateVersion ; "|" );
 
@UpdateFormulaContext;
@Command([RunAgent] ;"Set Template Version" )


Code formatted using Format Formula as HTML

Tagged as: 3 Comments
14Aug/052

Why Europeans Hate Americans

The Silent Republican has an idea why Europeans hate Americans:

"They're jealous. At least, that's the only way I can figure it. For more than a few centuries, they were on top of the world. They had empires stretching the globe and were major cultural centers. And when those empires started to crumble, and when those cultural centers began to shift to other countries, the Europeans were kicked out of the spotlight and replaced by newer countries, like the United States."

I find this hard to believe.

via: The Command T.O.C.

Filed under: General 2 Comments
11Aug/050

Using Version Numbers to Manage Database Designs

Welcome Chris Doig .  I don't even know Chris but I do like the first couple of posts though.  I will be Using Version Numbers to Manage Database Designs for all of my templates. I would like to see one additional feature, the ability to use Template Version from the template I want to version.  Chris, I have implemented this in Quick Elementer using toolbar or the Tools menu bar.  If started from Designer then I can select templates not just databases like Notes.

Template Version has been offically added to my list of free Domino development tools:

This is not like the Application Development Tools list that Alan  has created but there are a few new ones.

Here are a couple of ideas on how these tools could work together more.  

  • Having ScriptBrowser and display some of the LotusScript.doc information
  • LotusScript.doc report the template version information

via: For Your Reading Pleasure (or not)

10Aug/050

Quick Elementer and PickLists

I have been working on new design for the Quick Elementer.  My original goal was to have a small foot print, which has grown with the addition of some tags, and Quick Elementer Code. So I have abandoned that goal and now looking for a simpler UI. The selecting of design elements is the trickiest/unusual part of Quick Elementer.  

The new design will use views to select design elements instead of text. This will add a little more color and functionality.  I am also looking at a Quick Elementer Form which would act like the Quick Elmenter Code but work with Forms or Subforms.  Finally, I will be taking a look at the underlining code to see what improvements I can make.  I am sure there is some, there always is.

Just need more time, time, more time.

2Aug/050

Proverbs 3:27-30

27-Do not withhold good from those to whom it is due,
When it is in the power of your hand to do so.
28-Do not say to your neighbor,
"Go, and come back,
And tomorrow I will give it,"
When you have it with you.
29-Do not devise evil against your neighbor,
For he dwells by you for safety's sake.
30-Do not strive with a man without cause,
If he has done you no harm.
Tagged as: No Comments