Anxiety and attention mix in a complicated way. Relieving anxiety can calm down the brain enough so that it actually can pay better attention. Fixing an attention issue can help a person feel they're not missing stuff by drifting off in the middle of something important, which can make them feel less anxious. Seeing only an expert prescriber who really takes the time to understand the patient is very very important to figure out how best to treat the particular symptoms.
DeeDee
My eldest DD has a diagnosis of ADD, in progress of diagnosing with Aspergers. When she started stimulant medication the primary change she reported was reduced anxiety. Both general and social. We were aware that this might be due to improved attention reducing her anxiety about missing things, misunderstanding, doing the wrong thing, and helping her be more able to keep up and join in socially. So we stuck with the trial despite reduced anxiety not being what we were expecting her to report. After a few weeks she decided it wasn't really doing much after all and we were unable to clearly see a difference either (unlike our second child, in whom we see a daily difference). So she's no longer taking medication, but we are absolutely aware of that connection between attention and anxiety.