There's a bunch of people here who would love to help, but we need DETAILS!
Will it stay running if you hold the gas pedal down a little? Was the battery recently disconnected or run dead? Which engine do you have? What is the mileage? Did you inspect the idle air passage for carbon buildup? Does the engine stall while you're cruising? Just when approaching a stop sign? Does the engine speed go up to around 1500 rpm at startup, then come down to normal within a few seconds? Any service work done recently? How did you determine it needed an Automatic Idle Speed motor?