A. Whenever a Virginia resident has become liable to another state for income tax on any earned or business income or any gain on the sale of a capital asset (within the meaning of § 1221 of the Internal Revenue Code), not including an asset used in a trade or business, to the extent that such gain is included in federal adjusted gross income, for the taxable year, derived from sources outside the Commonwealth and subject to taxation under this chapter, the amount of such tax payable by him shall, upon proof of such payment, be credited on the taxpayer's return with the income tax so paid to the other state. However, no franchise tax, license tax, excise tax, unincorporated business tax, occupation tax or any tax characterized as such by the taxing jurisdiction, although applied to earned or business income, shall qualify for a credit under this section, nor shall any tax which, if characterized as an income tax or a commuter tax, would be illegal and unauthorized under such other state's controlling or enabling legislation qualify for a credit under this section.
The credit allowable under this section shall not exceed:
(i) such proportion of the income tax otherwise payable by him under this chapter as his income upon which the tax imposed by the other state was computed bears to his Virginia taxable income upon which the tax imposed by this Commonwealth was computed or(ii) the income tax otherwise payable under this chapter in the event that the income upon which the tax imposed by the other state is computed is less than the Virginia taxable income upon which the tax imposed by this Commonwealth is computed and all income derived from sources outside the Commonwealth and subject to taxation under this chapter is earned income or business income reported on federal form Schedule C from a single state contiguous to Virginia. The credit provided for by this section shall not be granted to a resident individual when the laws of another state, under which the income in question is subject to tax assessment, provide a credit to such resident individual substantially similar to that granted by subsection B of this section.