Variable Categories order not matching in Details panel

Stumbled on this thread while trying to find something else. But in case anyone still needs help with this, in C++ you can use the meta tags DisplayAfter or DisplayPriority to do this. For example:

UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = TestData, meta = (DisplayPriority="1"))
float TestFloat1;

UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = TestData, meta = (DisplayPriority="2"))
float TestFloat2

As long as the variables share the same category it will always make sure that they are displayed in that order. Hope this helps someone