If the income is not taxed in both states, you do not qualify to take the credit. Claiming the credit may inflate your refund and cause you to owe money to the state later.
Generally, Part Year returns calculate your tax based only on the income that was earned in the state (unlike resident returns, where your tax is generally calculated based on all of your income, regardless of where it was earned).
Some Part Year state returns start by calculating the total tax on all of your income. Then, your actual tax is calculated based on the percentage of your total income that was actually earned in the state. Because the result is a tax amount that is based only on the amount (or percentage) of income that was earned in the state, and not actually based on your total income from all sources, you generally cannot take a credit for the taxes you paid to another state.
Important: This credit is not simply a credit because you paid taxes to another state. It generally is only intended to be used to reduce a tax liability that is calculated based on income that was taxed by another state.