If you want the evaluation to halt until the Dialog returns you can get your code working very simply:
DynamicForm[row_, col_] :=
DialogInput[{x = ConstantArray[0, {row, col}], a},
Column[Flatten@{{Column[(Row[#] & /@
Table[With[{i = i, j = j},
InputField[Dynamic[x[[i, j]]], Number,
FieldSize -> Tiny]], {i, 1, row}, {j, 1, col}])],
{CancelButton[], DefaultButton[DialogReturn[x]]}}},
Spacings -> {1, Automatic}, Alignment -> Left]]
This allows you to just use DynamicForm in place of it's input in equations and such for instance: a=Transpose[DynamicForm[23,34]] will open a popup and assing a to the tranposed result upon pressing the OK button.
Update
If you don't want the dialog to return it's value, here is a version that puts the changes into a dynamically updated variable:
setDyn[a_Dynamic, val_] := Extract[a, 1, Function[{w}, w = val, HoldAll]];
DynamicForm[a_Dynamic, row_: 2, col_: 2] :=
CreateDialog[
DynamicModule[{x = ConstantArray[0, {row, col}]},
setDyn[a, x];
Column[{Grid@#1, Row@#2}, Spacings -> {1, Automatic}, Alignment -> Center]
& @@ {
Table[
With[{i = i, j = j},
InputField[
Dynamic[x[[i, j]],
Function[{val, nam}, nam = val; setDyn[a, x], HoldRest]],
Number, FieldSize -> Tiny]],
{i, row}, {j, col}],
{DefaultButton["Close", DialogReturn[]]}
}]
]
Called with DynamicForm[Dynamic[a],4,4] it will update a as you change it.