Process for preparing an amidine of the formula where p is an integer from 1 to 6 and r is an integer from 0 to 5, where (p+r) is an integer from 1 to 6, L is a (p+r)-valent hydrocarbyl radical having an average molecular weight in the range from 15 to 20'000 g/mol, optionally having heteroatoms, or, in the case that r = 0 and p = 1, may also be a hydrogen radical, Q is a reactive group selected from glycidoxy, N-aziridinyl, (meth)acrylate, (meth)acrylamide, (meth)acrylonitrile, maleate, maleamide, maleimide, fumarate, fumaramide, itaconate, itaconamide, crotonate and crotonamide, Q' is a divalent connecting unit formed from the reaction of a reactive Q group with HZ, and Z is an aliphatic amidine group bonded via a nitrogen atom, where every Z is separated from every other Z by at least 2 carbon atoms, and where, in the case that r = 0 and p = 1 and of (meth)acrylamide or maleamide or fumaramide or itaconamide or crotonamide as reactive Q group, L and Q' may also together be a monovalent hydrocarbyl radical having 5 to 20 carbon atoms and having heteroatoms in the form of amide groups and optionally ether or ester groups, characterized in that at least one amidine of the formula HZ is reacted with at least one functional compound of the formula L⁅Q] (p+r), where L is a (p+r)-valent hydrocarbyl radical having an average molecular weight in the range from 15 to 20'000 g/mol, optionally having heteroatoms, especially oxygen or nitrogen or silicon in the form of ether, tertiary amino, ester, amide, urethane, urea, uretdione, isocyanurate, biuret, allophanate, uretonimine, iminooxadiazinedione, oxadiazinetrione or alkoxysilane groups, or, in the case that r = 0 and p = 1, may also be a hydrogen radical, or, in the case that r = 0 and p = 1 and of (meth)acrylamide or maleamide or fumaramide or itaconamide or crotonamide as reactive Q group, L and Q' may also together be a monovalent hydrocarbyl radical having 5 to 20 carbon atoms and having heteroatoms in the form of amide groups and optionally ether or ester groups. p is an integer from 1 to 6 and r is an integer from 0 to 5, where (p+r) is an integer from 1 to 6, L is a (p+r)-valent hydrocarbyl radical having an average molecular weight in the range from 15 to 20'000 g/mol, optionally having heteroatoms, or, in the case that r = 0 and p = 1, may also be a hydrogen radical, a (p+r)-valent hydrocarbyl radical having an average molecular weight in the range from 15 to 20'000 g/mol, optionally having heteroatoms, or, in the case that r = 0 and p = 1, may also be a hydrogen radical, Q is a reactive group selected from glycidoxy, N-aziridinyl, (meth)acrylate, (meth)acrylamide, (meth)acrylonitrile, maleate, maleamide, maleimide, fumarate, fumaramide, itaconate, itaconamide, crotonate and crotonamide, Q' is a divalent connecting unit formed from the reaction of a reactive Q group with HZ, and Z is an aliphatic amidine group bonded via a nitrogen atom, where every Z is separated from every other Z by at least 2 carbon atoms, and where, in the case that r = 0 and p = 1 and of (meth)acrylamide or maleamide or fumaramide or itaconamide or crotonamide as reactive Q group, L and Q' may also together be a monovalent hydrocarbyl radical having 5 to 20 carbon atoms and having heteroatoms in the form of amide groups and optionally ether or ester groups, characterized in that at least one amidine of the formula HZ is reacted with at least one functional compound of the formula L⁅Q] (p+r), where L is a (p+r)-valent hydrocarbyl radical having an average molecular weight in the range from 15 to 20'000 g/mol, optionally having heteroatoms, especially oxygen or nitrogen or silicon in the form of ether, tertiary amino, ester, amide, urethane, urea, uretdione, isocyanurate, biuret, allophanate, uretonimine, iminooxadiazinedione, oxadiazinetrione or alkoxysilane groups, or, in the case that r = 0 and p = 1, may also be a hydrogen radical, or, in the case that r = 0 and p = 1 and of (meth)acrylamide or maleamide or fumaramide or itaconamide or crotonamide as reactive Q group, L and Q' may also together be a monovalent hydrocarbyl radical having 5 to 20 carbon atoms and having heteroatoms in the form of amide groups and optionally ether or ester groups. a (p+r)-valent hydrocarbyl radical having an average molecular weight in the range from 15 to 20'000 g/mol, optionally having heteroatoms, especially oxygen or nitrogen or silicon in the form of ether, tertiary amino, ester, amide, urethane, urea, uretdione, isocyanurate, biuret, allophanate, uretonimine, iminooxadiazinedione, oxadiazinetrione or alkoxysilane groups, or, in the case that r = 0 and p = 1, may also be a hydrogen radical, or, in the case that r = 0 and p = 1 and of (meth)acrylamide or maleamide or fumaramide or itaconamide or crotonamide as reactive Q group, L and Q' may also together be a monovalent hydrocarbyl radical having 5 to 20 carbon atoms and having heteroatoms in the form of amide groups and optionally ether or ester groups.