Get your taxes done using TurboTax

Ok.  Yes, if you are claiming a refund of withheld taxes you do have to file a New York return.  Just didn't want you to think you had to file a return in New York because the company was located there.

Filing as a resident of Maryland will not affect your Federal Foreign Tax Credit or the Health Care Exemption.  Both of those are based on a "number of days out of the US" calculation.  You can be out of the country on a temporary absence and still be considered a resident of a state.  Just like being out of the country does not affect your US citizenship status.