<PAGE>

                                                                 EXHIBIT 10.4
                                                                 ------------

                             EMPLOYMENT AGREEMENT

     THIS EMPLOYMENT AGREEMENT (this "Agreement") is made as of this 5/th/ day
of April, 2000, by and between Allscripts, Inc., a corporation organized and
existing under the laws of the State of Illinois, with its principal place of
business at 2401 Commerce Drive, Libertyville, Illinois 60048 ("Company"), and
Lee A. Shapiro ("Executive").

                                   RECITALS

     WHEREAS, the Company desires to employ Executive as its Executive Vice
President of Strategic Business Development; and

     WHEREAS, Executive desires to be employed by Company in the aforesaid
capacity.

     NOW THEREFORE, in consideration of the foregoing premises, of the mutual
agreements and covenants contained herein and for other good and valuable
consideration, the receipt and sufficiency of which are hereby acknowledged, the
parties agree as follows:

                                   AGREEMENT

     I.   Employment
          ----------

     The Company hereby agrees to employ Executive, and Executive hereby accepts
employment, as Executive Vice President of Strategic Business Development of the
Company, pursuant to the terms of this Agreement.  Executive shall report
directly to the Chief Executive Officer.  Executive shall have the duties and
responsibilities of Executive Vice President of Strategic Business Development,
and such other duties and responsibilities not inconsistent with the performance
of his duties and position as Executive Vice President of Strategic Business
Development as are reasonably assigned.

     II.  Effective Date and Term
          -----------------------

     The initial term of Executive's employment by the Company under this
Agreement shall commence as of April 5, 2000 and shall continue until April 30,
2003.  On April 30, 2003, and on each April 30 thereafter, this Agreement shall
automatically renew for a one (1) year term unless the Company or Executive
elects not to renew this Agreement in a written notice to the other party given
at least sixty (60) days preceding such April 30.  Executive's employment period
hereunder ("Employment Period") shall begin on April 5, 2000 and end on the
April 30 on which its term expires by reason of an election not to renew by the
Company or Executive ("Expiration Date") except that if Executive's employment
is terminated pursuant to Section IV hereof the Employment Period shall
terminate on the Effective Termination Date (as defined in Section IV).
<PAGE>

     III. Compensation and Benefits
          -------------------------

     In consideration for the services Executive shall render under this
Agreement, the Company shall provide or cause to be provided to Executive the
following compensation and benefits:

          A.   Base Salary
               -----------

          During the Employment Period, the Company shall pay or cause to be
paid to Executive an annual base salary at a rate of $225,000 for each twelve
month period ending April 30 ("Base Salary"), subject to all appropriate federal
and state withholding taxes and payable in accordance with the Company's normal
payroll procedures.  Such sum shall be reviewed prior to each April 30 during
the Employment Period by the Board of Directors of the Company (the "Board") or
its Compensation Committee for the purposes of determining appropriate merit
increases based on Executive's performance.  The results of such review shall be
reported to Executive prior to each such April 30.

          B.   Benefits
               --------

          During the Employment Period and as otherwise provided hereunder, the
Company shall provide or cause to be provided to Executive the following:

               1.   Twenty (20) business days per year of paid vacation, such
     vacation time not to be cumulative (i.e., vacation time not taken in one
     year shall not be carried forward and used in any subsequent year).

               2.   Health and/or dental insurance, including immediate coverage
     for Executive and his eligible dependents as provided by the Company in
     accordance with its group health insurance plan coverage applicable to
     senior executive employees;

               3.   To the extent that they do not duplicate benefits and
     perquisites provided in this Agreement, such other benefits and perquisites
     as are provided in accordance with the Company's plans, practices, policies
     and programs for senior executive employees of the Company; and

               4.   Indemnification (including immediate advancement of all
     legal fees with respect to any claim for indemnification) and directors'
     and officers' insurance coverage (to the extent made available to other
     senior executives).

          C.   Performance Bonus
               -----------------

          Executive shall be entitled to a cash bonus ("Performance Bonus") as
follows:  (i) a guaranteed annual bonus for each whole calendar year or portion
thereof falling within the Employment Period equal to at least the greater of
(x) twenty-five percent (25%) of the then current Base Salary and (y) $56,250,
and (ii) to the extent provided in Section IV, for the portion of the last
calendar year falling within the Employment Period if the Employment Period
terminates on the

                                       2
<PAGE>

Effective Termination Date. The Performance Bonus shall be payable on or before
April 30 of the year immediately succeeding the calendar year for which such
Performance Bonus was earned, provided, however, that if the applicable Company
objectives are based on the Company's annual audited financial statements and if
on such April 30 such financial statements have not yet been issued, the
Performance Bonus, if any, shall be payable promptly upon the issuance of such
financial statements.

          D.   Expenses
               --------

          The Company shall reimburse Executive for proper and necessary
expenses incurred by him in the performance of his duties under this Agreement
from time to time upon Executive's submission to the Company of invoices for
such expenses in reasonable detail.

          E.   Stock Awards
               ------------

          Executive shall be entitled to participate in any applicable stock
bonus, stock option or similar plan implemented by the Company including,
without limitation, the Company's Amended and Restated 1993 Stock Incentive Plan
approved by the Board and the Company's shareholders on or about June 7, 1999
(the "Plan"), on the following terms: (i) prior to the date hereof, Executive
      ----
received options to acquire 150,000 shares of common stock of the Company with
an exercise price of $44.625 per share, and Executive shall hereafter receive
additional grants for options under the Plan as approved by the Board
(collectively, "Options"), (ii) such Options shall vest over three (3) years
                -------
with twenty-five percent (25%) vesting on the grant date and a pro rata portion
of the balance vesting on the anniversary of the grant date over a three (3)
year period, (iii) all vested Options shall be free from forfeiture upon
termination of Executive's employment hereunder for any reason, (iv) the vesting
of such Options shall accelerate upon a Change in Control, termination without
Cause or termination by Executive for good reason (as each of the foregoing
terms is hereinafter defined), (v) "cashless" exercise provisions are included
in the terms of such Options and (vi) such other terms favorable to Executive as
are permitted under the Plan.   For purposes of this Agreement, the term "Change
in Control" shall mean any one of the following events:

               1.   The acquisition by any person or group of beneficial
     ownership of stock possessing more than 30% of the outstanding securities
     of the Company which generally entitle the holder thereof to vote for the
     election of directors, ("Voting Power"), except that (a) no such person or
     group shall be deemed to own beneficially (1) any securities acquired
     directly from the Company pursuant to a written agreement with the Company,
     or (2) any securities held by the Company or a Subsidiary of the Company
     ("Subsidiary"), or any employee benefit plan (or any related trust) of the
     Company or a Subsidiary, and (b) no Change in Control shall be deemed to
     have occurred solely by reason of any such acquisition by a corporation
     with respect to which, after such acquisition, more than 60% of both the
     then-outstanding common shares of such corporation and the Voting Power of
     such corporation are then beneficially owned, directly or indirectly, by
     the persons who were the beneficial owners of the stock and voting
     securities of the Company immediately before such acquisition in
     substantially the same proportions as their ownership, immediately before
     such

                                       3
<PAGE>

     acquisition, of the then outstanding stock or the Voting Power of the
     Company, as the case may be; or

               2.   individuals who, as of the date of this Agreement,
     constitute the Board (the "Incumbent Board") cease for any reason to
     constitute at least a majority of the Board, or the separation from
     employment with the Company of Glen E. Tullman; provided that any
     individual who becomes a director after the date of this Agreement whose
     election or nomination for election by the Company's stockholders was
     approved by a vote of at least two-thirds of the directors then comprising
     the Incumbent Board shall be considered as though such individual were a
     member of the Incumbent Board, but excluding, for this purpose, any such
     individual whose initial assumption of office is in connection with an
     actual or threatened election contest relating to the election of the
     directors of the Company (as such terms are used in Rule 14a-11 under the
     1934 Act); or

               3.   approval by the stockholders of the Company of (a) a merger,
     reorganization or consolidation with respect to which the individuals and
     entities who were the respective beneficial owners of the Common Stock and
     Voting Power of the Company immediately before such merger, reorganization,
     or consolidation do not, immediately after such merger, reorganization or
     consolidation, beneficially own, directly or indirectly, more than 60% of,
     respectively, the then outstanding common shares and the Voting Power of
     the corporation resulting from such merger, reorganization or
     consolidation, (b) a liquidation or dissolution of the Company or (c) the
     sale or other disposition of all or substantially all of the assets of the
     Company.

     For purpose of the foregoing definition, "beneficially ownership,"
"beneficially owned" and "beneficial ownership" and "person" mean such terms as
used in SEC rules 13d-5(b) under the 1934 Act, and "group" means two or more
persons acting together in such a way to be deemed a person for purposes of
Section 13(d) of the 1934 Act.

     IV.  Termination Prior to Expiration Date and Consequences Thereof
          -------------------------------------------------------------

     This Section IV sets forth the circumstances in which the Employment Period
shall terminate on a date ("Effective Termination Date") prior to the Expiration
Date (as defined in Section II hereof).

          A.   Death or Disability
               -------------------

          The Employment Period shall terminate upon Executive's date of death
or the date Executive is given written notice that he has been determined to be
disabled by the Company.  For purposes of this Agreement, Executive shall be
deemed to be "disabled" if Executive, as a result of illness or incapacity, (1)
shall be unable to perform substantially his required duties for a period of
three (3) consecutive months or for any aggregate period of three (3) months in
any six (6) month period.  In the event of a dispute as to whether Executive is
disabled, the Company may refer Executive to a licensed practicing physician of
the Company's choice, and Executive agrees to submit to such tests and
examination as such physician shall deem appropriate.

                                       4
<PAGE>

          B.   Termination by Company For Cause
               --------------------------------

          The Employment Period shall terminate on the date the Company provides
Executive with written notice that he is being terminated for Cause.

          For the purposes of this Agreement, the term "Cause" shall mean:

               (i)   the willful or grossly negligent failure by Executive to
     perform his duties and obligations hereunder in any material respect, other
     than any such failure resulting from his disability;

               (ii)  Executive's conviction of a felony crime; or

               (iii) Executive's violation of the law in connection with his
     employment which is materially and demonstrably injurious to the operations
     or reputation of the Company.

          Notwithstanding the foregoing, Cause shall not exist under clause (i)
above until notice of such failure has been given to Executive by the Company
and thirty (30) days has lapsed following such notice without Executive curing
such failure; provided, however, that such notice and lapse of time shall not be
required with respect to any event or circumstance which is the same or
substantially the same as an event or circumstance with respect to which notice
and an opportunity to cure has been given within the previous six (6) months.

          C.   Termination by Company Without Cause
               ------------------------------------

          The Employment Period shall terminate thirty (30) days following the
date the Company provides Executive with written notice that the Company is
exercising its rights under this Section IV(C) to terminate the Employment
Period without Cause.  If the Company elects not to renew this Agreement for any
renewal period pursuant to Section II hereof, such election shall not constitute
a termination of the Employment Period without Cause.

          D.   Termination by Executive for Good Reason
               ----------------------------------------

          The Employment Period shall terminate thirty (30) days following the
date Executive provides the Company with written notice that Executive is
exercising his right under this Section IV (D) to terminate the Employment
Period for good reason.  For purposes of this Agreement "good reason" shall
mean:

               (i)   a failure of the Company to meet its obligations in any
     material respect under this Agreement which remains uncured after Executive
     has provided written notice of such failure and one (1) week has elapsed
     following such notice without the Company curing such failure; provided,
     however, that such notice and lapse of time shall not be required with
     respect to any event or circumstance which is the same or substantially the

                                       5
<PAGE>

     same as an event or circumstance with respect to which notice and an
     opportunity to cure has been given within the previous six (6) months;

               (ii)  a substantial adverse alteration in the nature or status of
     Executive's responsibilities with the Company;

               (iii) a request of Executive to relocate his residence greater
     than 100 miles from his then current residence without his consent; and an
     exercise by him of his right under this Section IV (D) within sixty (60)
     days after such request; or

               (iv)  termination of Executive's employment by the Company or
     Executive for any reason other than Cause during the one (1) year period
     immediately following a Change in Control shall be deemed a termination for
     good reason; provided, however, that if Executive dies after a Change in
     Control by less than one year thereafter, Executive will be deemed to have
     terminated employment pursuant to this clause (iv) immediately prior to his
     death.

          E.   Termination by Executive Without Good Reason
               --------------------------------------------

          The Employment Period shall end thirty (30) days following the date
Executive provides the Company with written notice that Executive is exercising
his right under this Section IV (E) to terminate the Employment Period without
good reason.  If Executive elects not to renew this Agreement for any renewal
period pursuant to Section II hereof, such election shall not constitute a
termination of the Employment Period without good reason.

          F.   Consequence of Termination Under this Section IV
               ------------------------------------------------

          The table at the end of this Section IV (F) sets out the consequences
of a termination of the Employment Period on the Effective Termination Date,
i.e., a date other than the Expiration Date as defined in Section II.  Such
----
consequences are as follows:

               1.   Termination Without Cause or for Good Reason. If the Company
                    --------------------------------------------
     exercises its right to terminate the Employment Period without Cause or if
     Executive exercises his right to terminate the Employment Period for good
     reason, the Company shall be obligated to pay Executive (or provide
     Executive with) the following benefits: (a) any salary that was accrued but
     not yet paid as of the Effective Termination Date; (b) as severance pay, an
     amount, payable in twelve (12) equal monthly installments commencing on the
     Effective Termination Date, equal to Executive's annual Base Salary in
     effect immediately prior to the Effective Termination Date for the greater
     of twelve (12) months or the remainder of the then current Employment
     Period (such amount to be payable regardless of whether (x) Executive
     obtains other employment and is compensated therefor, (y) the Effective
     Termination Date is less than twelve (12) months prior to the Expiration
     Date or (z) Executive dies prior to the first anniversary of the Effective
     Termination Date,

                                       6
<PAGE>

     but only for so long as Executive is not in violation of Section V hereof);
     (c) the unpaid Performance Bonus with respect to the calendar year
     preceding the Effective Termination Date (such Performance Bonus to be
     determined in the manner it would have been determined and payable at the
     time it would have been payable under Section III(C) had there been no
     termination of the Employment Period); (d) the Performance Bonus for the
     calendar year in which the Effective Termination Date occurs that would
     have been payable under Section III(C) had there been no termination of the
     Employment Period (such Performance Bonus to be determined in the manner it
     would have been determined and payable at the time it would have been
     payable under Section III(C) had there been no termination of the
     Employment Period); (e) the benefits set forth in Section III (B) for a
     period of twelve (12) months after such termination and the Company shall
     comply with any and all state and federal laws and regulations applying to
     such benefits; (f) any Options granted to Executive pursuant to Section III
     (E) that have not vested as of the date of such termination shall vest in
     full and; (g) the loans made to Executive by the Company pursuant to
     Section III (G) shall be forgiven and canceled; and (h) outplacement
     services, at the expense of the Company, from a provider reasonably
     selected by Executive. Notwithstanding the foregoing, in the event that
     this Agreement terminates by reason of Section IV(D)(iv), then Executive
     shall receive, in addition to the compensation and benefits described in
     clauses (a), (e), (f), (g) and (h) above, the following benefits:

               (i)   A cash bonus for the year of termination, calculated as a
     pro rata portion of the greater of (A) Executive's target annual bonus for
     the year of termination or (B) the amount determined and paid in accordance
     with the terms of the then current annual bonus plan applicable to
     Executive,

               (ii)  Payment in a lump sum of an amount equal to 2.99 times
     Executive's base salary as in effect pursuant to Section III A above prior
     to the termination;

               (iii) Payment in a lump sum of an amount equal to 2.99 times
     Executive's target annual bonus pursuant to Section III C above for the
     fiscal year of termination; and

               (iv)  Continuation, for a period of two (2) years after the date
     of termination, of medical and dental benefits, life insurance and
     executive physical examinations at least equal to those which would have
     been provided if Executive's employment had continued for that time, but
     such benefits under this clause (d) may be discontinued earlier to the
     extent that Executive becomes entitled to comparable benefits from a
     subsequent employer.

               2.    Termination With Cause or Without Good Reason.  If the
                     ---------------------------------------------
     Company exercises its right to terminate the Employment Period with Cause
     or if Executive exercises his right to terminate the Employment Period
     without good reason, the Company shall be obligated to pay Executive (a)
     any salary that was accrued but not yet paid as of the Effective
     Termination Date; and (b) the unpaid Performance Bonus with respect to the
     calendar year preceding the Effective Termination Date (such Performance
     Bonus to be determined in the

                                       7
<PAGE>

     manner it would have been determined and payable at the time it would have
     been payable under Section III(C) had there been no termination of the
     Employment Period).

               3.   Termination Upon Death or Disability.  If the Employment
                    ------------------------------------
     Period is terminated because of the death or disability of Executive, the
     Company shall be obligated to pay Executive or, if applicable, Executive's
     estate (a) any salary that was accrued but not yet paid as of the Effective
     Termination Date; (b) the unpaid Performance Bonus with respect to the
     calendar year preceding the Effective Termination Date (such Performance
     Bonus, if any, to be determined in the manner it would have been determined
     and payable at the time it would have been payable under Section III(C) had
     there been no termination of the Employment Period); and (c) the
     Performance Bonus for the calendar year in which the Effective Termination
     Date occurs that would have been payable under Section III(C) had there
     been no termination of the Employment Period (such Performance Bonus to be
     determined in the manner it would have been determined and payable at the
     time it would have been payable under Section III(C) had there been no
     termination of the Employment Period).

<TABLE>
<CAPTION>
                   Table Setting Out Consequences of a Termination of Employment
                   -------------------------------------------------------------
                              Period on the Effective Termination Date
                              ----------------------------------------

Paragraph                         Salary                     Severance       Benefits      Options
Reference                        Ceases?        Bonus?         Paid?        Continue?       Vest?
---------                        -------        ------         -----        ---------       -----
<S>                              <C>          <C>            <C>           <C>             <C>
(A)  Death or Disability           Yes        Full Bonus         No        No on death        No
                                                                              Yes on
                                                                            disability

(B)  Company terminates for        Yes         No Bonus          No            Yes            No
     Cause

(C)  Company terminates            Yes        Full Bonus        Yes            Yes           Yes
     without Cause

(D)  Executive terminates for      Yes        Full Bonus        Yes            Yes           Yes
     good reason

(E)  Executive terminates          Yes        Prior year         No            Yes            No
     without good reason                         only
</TABLE>

     Notwithstanding anything contained herein to the contrary, the foregoing
table is subject to the foregoing provisions of this Section IV (F).

     V.   Noncompetition and Confidentiality
          ----------------------------------

          A.   For purposes of this Agreement, the term "Direct Competitor"
shall mean any person or entity engaged in the business of marketing or
providing within the continental United States prescription products or services
or pharmacy benefit management products or services, including, without
limitation, prepackaged prescription products or services, point of care
pharmacy

                                       8
<PAGE>

dispensing systems, mail service pharmacy products or services, or
pharmaceuticals or pharmaceutical delivery systems.

          B.   During the Employment Period and for a period of one (1) year
after the termination of the Employment Period for any reason, Executive shall
not, (i) directly or indirectly act in concert or conspire with any person
employed by the Company in order to engage in or prepare to engage in or to have
a financial or other interest in any business which is a Direct Competitor; or
(ii) serve as an employee, agent, partner, shareholder, director or consultant
for, or in any other capacity participate, engage or have a financial or other
interest in any business which is a Direct Competitor (provided, however that
notwithstanding anything to the contrary contained in this Agreement, Executive
may own up to 2% of the outstanding shares of the capital stock of a company
whose securities are registered under Section 12 of the Securities Exchange Act
of 1934).

           C.  The Company has advised Executive and Executive acknowledges that
it is the policy of the Company to maintain as secret and confidential all
Protected Information (as defined below), and that Protected Information has
been and will be developed at substantial cost and effort to the Company.
Executive shall not at any time, directly or indirectly, divulge, furnish or
make accessible to any person, firm, corporation, association or other entity
(otherwise than as may be required in the regular course of Executive's
employment), nor use in any manner, either during the Employment Period or after
the termination, for any reason, of the Employment Period, any Protected
Information, or cause any such information of the Company to enter the public
domain, except as required by law or court order. "Protected Information" means
trade secrets, confidential and proprietary business information of the Company,
and any other information of the Company, including but not limited to, customer
lists (including potential customers), sources of supply, processes, plans,
materials, pricing information, internal memoranda, marketing plans, internal
policies, and products and services which may be developed from time to time by
the Company and its agents or employees, including Executive; provided, however,
that information that is in the public domain (other than as a result of a
breach of this Agreement), approved for release by the Company or lawfully
obtained from third parties who are not bound by a confidentiality agreement
with the Company, is not Protected Information.

          D.   Executive acknowledges and agrees that the restrictions imposed
upon him by this Section V and the purpose for such restrictions are reasonable
and are designed to protect the Protected Information and the continued success
of the Company without unduly restricting Executive's future employment by
others. Furthermore, Executive acknowledges that in view of the Protected
Information of the Company which he has or will acquire or has or will have
access to and the necessity of the restrictions contained in this Section V, any
violation of the provisions of this Section V would cause irreparable injury to
the Company and its successors in interest with respect to the resulting
disruption in their operations. By reason of the foregoing, Executive consents
and agrees that if he violates any of the provisions of this Section V, the
Company and its successors in interest, as the case may be, shall be entitled,
in addition to any other remedies that they may have, including monetary
damages, to an injunction to be issued by a court of competent jurisdiction,
restraining Executive from committing or continuing any violation of this
Section V.

     VI.  Certain Additional Payments by the Company.  The Company agrees that:
          ------------------------------------------

                                       9
<PAGE>

          A.   Anything in this Agreement to the contrary notwithstanding, in
the event it shall be determined that any payment or distribution by the Company
to or for the benefit of Executive (whether paid or payable or distributed or
distributable pursuant to the terms of this Agreement or otherwise, but
determined without regard to any additional payments required under this Section
VI) (a "Payment") would be subject to the excise tax imposed by Section 4999 of
the Code or if any interest or penalties are incurred by Executive with respect
to such excise tax (such excise tax, together with any such interest and
penalties, being hereinafter collectively referred to as the "Excise Tax"), then
Executive shall be entitled to receive an additional payment (a "Gross-Up
Payment") in an amount such that, after payment by Executive of all taxes
(including any interest or penalties imposed with respect to such taxes),
including, without limitation, any income taxes (and any interest and penalties
imposed with respect thereto) and Excise Tax imposed upon the Gross-Up Payment,
Executive retains an amount of the Gross-Up Payment equal to the Excise Tax
imposed upon the Payment.

          B.   Subject to the provisions of Section VI (C), below, all
determinations required to be made under this Section VI, including whether and
when a Gross-Up Payment is required and the amount of such Gross-Up Payment and
the assumptions to be utilized in arriving at such determination, shall be made
by the accounting firm which is then serving as the auditors for the Company
(the "Accounting Firm"), which shall provide detailed supporting calculations
both to the Company and Executive within fifteen (15) business days of the
receipt of notice from Executive that there has been a Payment, or such earlier
time as is requested by the Company. In the event that the Accounting Firm is
serving as accountant or auditor for the individual, entity or group effecting
the Change in Control, Executive shall appoint another nationally recognized
accounting firm to make the determinations required hereunder (which accounting
firm shall then be referred to as the Accounting Firm hereunder). All fees and
expenses of the Accounting Firm shall be borne solely by the Company. Any Gross-
Up Payment, as determined pursuant to this Section VI, shall be paid by the
Company to Executive within five (5) days of the receipt of the Accounting
Firm's determination. If the Accounting Firm determines that no Excise Tax is
payable by Executive, it shall furnish Executive with a written opinion that
failure to report the Excise Tax on Executive's applicable federal income tax
return would not result in the imposition of a negligence or similar penalty.
Any good faith determination by the Accounting Firm shall be binding upon the
Company and Executive. As a result of the uncertainty in the application of
Section 4999 of the Code at the time of the initial determination by the
Accounting Firm hereunder, it is possible that Gross-Up Payments which will not
have been made by the Company should have been made ("Underpayment"), consistent
with the calculations required to be made hereunder. In the event that the
Company exhausts its remedies pursuant to Section VI (C), below, and Executive
thereafter is required to make a payment of any Excise Tax, the Accounting Firm
shall determine the amount of the Underpayment that has occurred and any such
Underpayment shall be promptly paid by the Company to or for the benefit of
Executive.

          C.   Executive shall notify the Company in writing of any claim by the
Internal Revenue Service that, if successful, would require the payment by the
Company of a Gross-Up Payment. Such notification shall be given as soon as
practicable but no later than fifteen (15) business days after Executive is
informed in writing of such claim and shall apprise the Company

                                       10
<PAGE>

of the nature of such claim and the date on which such claim is requested to be
paid. Executive shall not pay such claim prior to the expiration of the thirty
(30) day period following the date on which Executive gives such notice to the
Company (or such shorter period ending on the date that any payment of taxes
with respect to such claim is due). If the Company notifies Executive in writing
prior to the expiration of such period that it desires to contest such claim,
Executive shall:

               (i)   Give the Company any information reasonably requested by
     the Company relating to such claim;

               (ii)  Take such action in connection with contesting such claim
     as the Company shall reasonably request in writing from time to time,
     including, without limitation, accepting legal representation with respect
     to such claim by an attorney reasonably selected by the Company;

               (iii) Cooperate with the Company in good faith in order
     effectively to contest such claim; and

               (iv)  Permit the Company to participate in any proceedings
     relating to such claim;

provided, however, that the Company shall bear and pay directly all costs and
expenses (including additional interest and penalties) incurred in connection
with such contest and shall indemnify and hold Executive harmless, on an after-
tax basis, for any Excise Tax or income tax (including interest and penalties
with respect thereto) imposed as a result of such representation and payment of
costs and expenses.  Without limiting the foregoing provisions of this Section
VI (C), the Company shall control all proceedings taken in connection with such
contest and, at its sole option, may pursue or forego any and all administrative
appeals, proceedings, hearings and conferences with the taxing authority in
respect of such claim and may, at its sole option, either direct Executive to
pay the tax claimed and sue for a refund or contest the claim in any permissible
manner; and Executive agrees to prosecute such contest to a determination before
any administrative tribunal, in a court of initial jurisdiction and in one or
more appellate courts, as the Company shall determine; provided further,
however, that if the Company directs Executive to pay such claim and sue for a
refund, the Company shall advance the amount of such payment to Executive on an
interest-free basis and shall indemnify and hold Executive harmless, on an
after-tax basis, from any Excise Tax or income tax (including interest or
penalties with respect thereto) imposed with respect to such advance or with
respect to any imputed income with respect to such advance; and further provided
that any extension of the statute of limitations relating to payment of taxes
for the taxable year of Executive with respect to which such contested amount is
claimed to be due is limited solely to such contested amount.  Furthermore, the
Company's control of the contest shall be limited to issues with respect to
which a Gross-Up Payment would be payable hereunder and Executive shall be
entitled to settle or contest, as the case may be, any other issue raised by the
Internal Revenue Service or any other taxing authority.

          D.   If, after the receipt by Executive of an amount advanced by the
Company pursuant to Section VI (C) above, Executive becomes entitled to receive
any refund with respect to

                                       11
<PAGE>

such claim, Executive shall (subject to the Company's complying with the
requirements of said Section VI (C)) promptly pay to the Company the amount of
such refund (together with any interest paid or credited thereon, after taxes
applicable thereto). If, after the receipt by Executive of an amount advanced by
the Company pursuant to said Section VI (C), a determination is made that
Executive shall not be entitled to any refund with respect to such claim and the
Company does not notify Executive in writing of its intent to contest such
denial of refund prior to the expiration of thirty (30) days after such
determination, then such advance shall be forgiven and shall not be required to
be repaid; and the amount of such advance shall offset, to the extent thereof,
the amount of the Gross-Up Payment required to be paid.

     VII.  No Set-Off or Mitigation.  The Company's obligation to make the
           ------------------------
payments provided for in this Agreement and otherwise to perform its obligations
hereunder shall not be affected by any set-off, counterclaim, recoupment,
defense or other claim, right or action which the Company may have against
Executive or others.  In no event shall Executive be obligated to seek other
employment or take any other action by way of mitigation of the amounts payable
to Executive under any of the provisions of this Agreement and such amounts
shall not be reduced whether or not Executive obtains other employment.

     VIII. Payment of Certain Expenses.  The Company agrees to pay promptly as
           ---------------------------
incurred, to the fullest extent permitted by law, all legal fees and expenses
which Executive may reasonably incur as a result of any contest by the Company,
Executive or others of the validity or enforceability of, or liability under,
any provision of this Agreement (including as a result of any contest initiated
by Executive about the amount of any payment due pursuant to this Agreement),
plus in each case interest on any delayed payment at the applicable federal rate
provided for in Section 7872(f)(2)(A) of the Code; provided, however, that the
Company shall not be obligated to make such payment with respect to any contest
in which the Company prevails over Executive.

     IX.   Indemnification.  To the full extent permitted by law, the Company
           ---------------
shall indemnify Executive (including the advancement of expenses) for any
judgments, fines, amounts paid in settlement and reasonable expenses, including
attorneys' fees, incurred by Executive in connection with the defense of any
lawsuit or other claim to which he is made a party by reason of being an
officer, director or employee of the Company or any of its subsidiaries.

     X.    Miscellaneous
           -------------

           A.  Valid Obligation
               ----------------

           This Agreement has been duly authorized, executed and delivered by
the Company and has been duly executed and delivered by Executive and is a
legal, valid and binding obligation of the Company and of Executive, enforceable
in accordance with its terms.

           B.  No Conflicts
               ------------

                                       12
<PAGE>

          Executive represents and warrants that the performance by him of his
duties hereunder will not violate, conflict with or result in a breach of any
provision of, any agreement to which he is a party.

          C.   Applicable Law
               --------------

          This Agreement shall be construed in accordance with the laws of the
State of Illinois, without reference to Illinois' choice of law statutes or
decisions.

          D.   Severability
               ------------

          The provisions of this Agreement shall be deemed severable, and the
invalidity or unenforceability of any one or more of the provisions hereof shall
not affect the validity or enforceability of any other provision.  In the event
any clause of this Agreement is deemed to be invalid, the parties shall endeavor
to modify that clause in a manner which carries out the intent of the parties in
executing this Agreement.

          E.   No Waiver
               ---------

          The waiver of a breach of any provision of this Agreement by any party
shall not be deemed or held to be a continuing waiver of such breach or a waiver
of any subsequent breach of any provision of this Agreement or as nullifying the
effectiveness of such provision, unless agreed to in writing by the parties.

          F.   Notices
               -------

          All notices hereunder shall be in writing and shall be sent by hand
delivery, overnight courier, or by certified mail, return receipt requested, to
the parties at the addresses set forth below:

                    To the Company:  Allscripts, Inc.
                                     2401 Commerce Drive
                                     Libertyville, Illinois 60048
                                     Attention: Chief Executive Officer

                    with a copy to:  Gardner, Carton & Douglas
                                     321 North Clark Street
                                     Chicago, Illinois 60610
                                     Attention: Joseph H. Greenberg

                    to Executive:    Lee A. Shapiro
                                     2211 Schiller
                                     Wilmette, Illinois 60091


                                       13
<PAGE>

                      with a copy to:   Vedder Price
                                        222 North LaSalle
                                        Chicago, IL 60601
                                        Attention: Michael Nemeroff

          G.   Assignment of Agreement
               -----------------------

          This Agreement shall inure to the benefit of Executive and the
Company, their respective successors and assignees and Executive's heirs and
personal representatives.  Neither party may assign any rights or obligations
hereunder to any person or entity without the prior written consent of the other
party.  This Agreement shall be personal to Executive for all purposes.

          H.   Entire Agreement
               ----------------

          Except as otherwise provided herein, this Agreement contains the
entire understanding between the parties, and there are no other agreements or
understandings between the parties with respect to Executive's employment by the
Company and his obligations thereto.  Executive acknowledges that he is not
relying upon any representations or warranties concerning his employment by the
Company except as expressly set forth herein.  No alteration or modification
hereof shall be valid except by a subsequent written instrument executed by the
parties hereto.

          I.   Dispute Resolution and Arbitration
               ----------------------------------

          The following procedures shall be used in the resolution of disputes:

               1.   Dispute.  In the event of any dispute or disagreement
                    -------
     between the parties under this Agreement, the disputing parties shall set
     forth their respective positions and disagreements in writing, formally,
     and give them, together with written notice of the same, to each other, to
     the effect that such dispute exists. The parties will then make a good
     faith effort to resolve the dispute or disagreement. If the dispute is not
     resolved at the expiration of fifteen (15) days from the time a party
     receives such notice and statement from the other party, the entire matter
     shall then be submitted to arbitration as set forth in the paragraph
     immediately herein below.

               2.   Arbitration.  If the dispute or disagreement between the
                    -----------
     parties has not been resolved in accordance with the provisions of sub-
     paragraph (a) above, then any such controversy or claim arising out of or
     relating to this Agreement, or the breach thereof, shall be settled by
     arbitration to be held in Chicago, Illinois, in accordance with the rules
     of the American Arbitration Association then in effect. Any decision
     rendered herein shall be final and binding on each of the parties and
     judgment may be entered thereon in the appropriate

                                       14
<PAGE>

     state or federal court. The arbitrators shall be bound to strict
     interpretation and observation of the terms of this Agreement. The Company
     shall pay the costs of arbitration.

                           [Signature Page Follows]

                                       15
<PAGE>

     IN WITNESS WHEREOF, the parties have executed this Agreement as of the date
and year first above written.

                                             ALLSCRIPTS, INC.


                                             By: /s/  Glen E. Tullman
                                                -----------------------------
                                             Name: Glen E. Tullman
                                                   --------------------------
                                             Title: CEO
                                                    -------------------------


                                             /s/  Lee A. Shapiro
                                             --------------------------------
                                                  Lee A. Shapiro

                                       16