I think you are trying to do something like this:
proc iml;
start Func(x) global(a,b);
return(a*x##2-b);
finish;
a = 1;
b = 2;
bounds = {-2 0,
0 2};
roots = froot( "Func", bounds);
print roots;
The FROOT function is a numerical root-finder, which means that all symbols must have assigned values. Note also that the FROOT function will return one root for each interval that you specify. If you think you have multiple roots but do not have a good estimate for the intervals on which they occur, read the article "Finding roots: Automating the search for an initial guess."
If you are looking for a SYMBOLIC answer (like the quadratic formula) that gives x in terms of symbolic parameters a and b, then you need to use symbolic software such as Wolfram Alpha. However, only a very small number of functions are invertible.
... View more