OK.. Thanks, understood. One I should bear in mind to tidy up later however I think we are still at cross purposes.
When I say I 'write a text file' I am not doing that within the program I am using a text editor and typing the information in by hand. The program reads in that text file and creates the objects.
I was writing the data in the text file out as records after parsing it in the hope that things would load up more quickly subsequently. This WriteComponents definitely looks like the proper way to do it however I need to have the components in place before I can write them out.
Either I can do it the 'proper' way and use the IDE to design the form or I can do it my, stupid, way by writing a text file by hand loading the components in from that file and then write them back out again using this WriteComponents method.
For my sins, apart from the grief of getting the thing working, I believe using a text file to initially define the components will, dare I say, ultimately be more productive. As you suggest there are many 'defaults' and other things I may not generally be interested in but using the IDE I have to find the others to set them up.. and then move things about with the mouse or whatever.
Otherwise I can take a 'base' set and for example
#Prototype Panel;
#01 [TYPE 01]Integer
#02 [INDEX]Integer*
#03 [ALIGN](0{None},1{Left},2{Right},3{Top},4{Bottom},5{Client},6{Custom},7{Relative})
#04 [ANCHORS]{Top,Left,Right,Bottom; 0000}
#05 [TOP]Integer
#06 [HEIGHT]Integer
#07 [LEFT]Integer
#08 [WIDTH]Integer
#09 [PercentLeft]Integer
#10 [PercentRight]Integer
#11 [CAPTION]String
#12 [Color](0{clButnFace},1{clMoneyGreen}3{clEtc},#{colorstring}
#13 [Color](0{clButnFace},1{clMoneyGreen}3{clEtc},#{colorstring}
#14 [EVENT]Integer
#15 [Linkage]Integer
and
#Prototype Splitter;
#01 [TYPE 02]Integer
#02 [INDEX]Integer*
#03 [ALIGN](0{None},1{Left},2{Right},3{Top},4{Bottom},5{Client},6{Custom},7{Relative})
#04 [ANCHORS]{Top,Left,Right,Bottom; 0000}
#05 [TOP]Integer
#06 [HEIGHT]Integer
#07 [LEFT]Integer
#08 [WIDTH]Integer
#09 [PercentLeft]Integer
#10 [PercentRight]Integer
#11 [CAPTION]String,
#12 [Color](0{clButnFace},1{clMoneyGreen}3{clEtc},#{colorstring}
#13 [Color](0{clButnFace},1{clMoneyGreen}3{clEtc},#{colorstring}
#14 [EVENT]Integer
#15 [Linkage]Integer
Then if I want to design a form based on Panels and Splitters my text file might look like this
,02,,1,0000,000,003,000,003,000,000,Nil,1,0,0,0, //place a splitter align left.
,01,,1,0000,000,000,000,200,000,000,Nil,1,0,1,0, //place a panel align left
,01,,5,0000,000,000,000,200,000,000,Nil,1,0,1,0, //place a panel align client
,02,,3,0000,000,003,000,003,000,000,Nil,1,0,0,0, //place a splitter align top
,01,,3,0000,000,000,000,200,000,000,Nil,1,0,1,0, //place a panel align top
,01,,5,0000,000,000,000,200,000,000,Nil,1,0,1,0, //place a panel align client
,02,,1,0000,000,003,000,003,000,000,Nil,1,0,0,0, //place a splitter align left
,01,,1,0000,000,000,000,200,000,000,Nil,1,0,1,0, //place a panel align left
,01,,5,0000,000,000,000,200,000,000,Nil,1,0,1,0, //place a panel align client
With the indents sorting out the parentage, zero indent places the component on the parent form and then it works back from there. If, on loading things, they do not look right then rather than finding the appropriate control and then looking for the attribute in the object inspector or dragging it about I can just go back to the text file and, hopefully, quickly modify the 'offending' entry then reload it to see how things are going.
Once I am happy with it then I can write things out properly for future use using this WriteComponents method.
As things stand I am stuck with TSplitters that do not wish to play nicely. Sorry for providing too much confusing background information.