In a previous article, we presented a mathematical tool for the systematic calculation of the critical buckling load and the buckling mode of any frame, under some simplificative hypothesis. The present work extends this formulation to provide greater generality, considering the possibility of analyzing variable section beams under any kind of loads (including any distributed load and linear variation of the temperature in the edge of the profile). With this purpose, we consider the equilibrium equations of each beam in its deformed configuration, under the hypothesis of infinitesimal strains and displacements, so called First-Order Theory, resulting in a system of di®erential equations with variable coefficients for each element. To obtain the nonlinear response of the frame, it is necessary to impose in each beam end the compatibility of displacements and the equilibrium of forces and moments, also in the deformed configuration. The solution is obtained by requiring that the total variation of potential energy is zero at the instant of buckling. The objective of this work is to develop a systematic method to determine the critical buckling load and the buckling mode of any frame, without using the common simplifications usually assumed in matrix analysis or finite element approaches. This allows us to obtain precise results regardless of the discretization done.