ROOT::Math::Minimizer on windows

Hi,
I’m developing a program on Windows with Qt and mvsc 18 (visual studio 2013) compiler.
I need perform some minimization with root and I’m basically following this example
https://root.cern.ch/root/html534/tutorials/fit/NumericalMinimization.C.html
which is working if i run it from root
but in my program the line

ROOT::Math::Minimizer* min =ROOT::Math::Factory::CreateMinimizer(minName, algoName);

can’t initialize the minimizer and after I get a null pointer.
Can someone help me?

Update:
I got it working bypassing the factory creation method ad calling directly

so i suppose there something wrong with the factory.

HI,

It should have worked also using the Factory() method (i.e. with the plug-in manager). Which minimiser name did you use, “Minuit2” ?
In case, can you add the line gDebug=1 and send me the resulting messages printed, to understand better what failed.

Best Regards

Lorenzo