TECHNOLOGY FOCUS - INORGANIC CHEMISTRY - Preferred Method: The surfactants and solvent are in molar ratios in the following ranges with respect to the central element X in the covalent metal complexes: surfactant/X: a molar ratio of 1asterisk10-7 to 0.1, solvent/X: a molar ratio of 3-50. The sol further comprises at least one condensation inhibitor and/or water in molar ratios in the following ranges with respect to the central element X: condensation inhibitor/X: a molar ratio of 0-5.0, water/X: a molar ratio of 0-20. The step of controlling the size of pores includes at least one of the following: adding a chelating agent to the precursor sol, using a solvent/X molar ratio of 14-30 in the precursor sol, where X is a central element in at least one of the covalent metal complex; adding a pore-swelling agent to the precursor sol, or using a block co-polymer having a molecular weight of 5000-14000 g per mol as the surfactant in the precursor sol. The step of controlling the pore size includes adding a chelating agent (a1). The chelating agent is added to the sol in a molar ratio chelating agent/X of 0.1-5 (preferably 1-3). The step of controlling the pore size includes adding a pore-swelling agent chosen from trimethylbenzene, triton, chatecol, butanol, pentanol, hexanol, octanol, polypropylene glycols, latex, octane, isooctane, formamide, other hydrophobic surfactants, and surfactants that can form mixed micelles. The pore-swelling agent is added to the sol in a molar ratio X/pore-swelling agent of 0.3-10. The step of controlling the pore size includes using as the surfactant in the precursor sol a block co-polymer having a molecular weight of 5000-14000 g per mol, where the block co-polymer is selected from diblock and triblock copolymers. The method further involves controlling the spacing between adjacent pores, such that adjacent pores are 10-50 nm. The step of controlling the spacing between adjacent pores includes using a molar ratio of X/surfactant of 100-1asterisk106; and using a molar ratio of X/solvent of 0.02-0.1. The step of controlling the spacing between adjacent pores includes adding a pore swelling agent (PSA) in a molar ratio of X/PSA of 0.3-10. The step of controlling the size of pores includes adding a chelating agent in a molar ratio of X/chelating agent of 1-3, where the chelating agent is HOAc or acetoxyacetone. The method further involves filling the pores in the nanostructured porous layer with a semiconducting or conducting pore-filling material, where the pore-filling material has complementary charge transfer properties with respect to the compound of central element X. Preferred Components: The central element X in the covalent metal complexes is a metal, a transition metal or Al, B, Ba, Ce, Ge, Hf, In, La, Pb, Os, Se, Si, Sn, Sr, or Va, (preferably titanium (Ti)).    TECHNOLOGY FOCUS - ORGANIC CHEMISTRY - Preferred Components: The chelating agent (a1) is selected from ketones, B-diketones, carboxylic acids, B-keto-carboxylic acids, diols, aminoalcohols, crown ethers, hydroxyl or amine containing polymers, small molecules or cosolvents such as ethyl acetoacetate, 2,4-pentadione, acetone, diacetone alcohol, acetic acid, stearic acid, lactic acid, chatecol, or triethanolamine. The pore-filling material is selected from perylenes, phtalocyanines, merocyanines, terylenes, squaraines, ruthenium complexes, pentacenes, naphthalocyanines, spirocompounds, conjugated C-60, dendrimers, or their derivatives.    TECHNOLOGY FOCUS - POLYMERS - Preferred Components: The pore-filling material is selected from poly(phenylene), polyphenylvinylene, poly(isothianaphthene), polyfluorenes, polyparaphenylene, poly(squaraine), poly(3,4-ethylenedioxythiophene) (PEDOT), poly(thiophene), polyacetylene, conjugated C-60, polyaniline, or their derivatives. EXAMPLE - No suitable example given.