James 5:14-15 NKJV
Is anyone among you sick? Let him call for the elders of the church, and let them pray over him, anointing him with oil in the name of the Lord. And the prayer of faith will save the sick, and the Lord will raise him up. And if he has committed sins, he will be forgiven.
When the elders ministered to the sick in the church, they were instructed to apply oil in the name of Jesus. The process was to be as follows:
1. The sick members would request ministry from the elders.
2. The elders would pray the prayer of faith over them while anointing them with oil in the name of the Lord.
3. The prayer of faith administered as described would result in the sick being saved (from their sickness) and raised up by the Lord. (They would also be forgiven if sin was involved.)
The oil would primarily represent the anointing of the Holy Spirit in this case. This lets us know that we are to expect the ministry of the Holy Spirit to be active in our healing. This is consistent with what Paul taught.
1 Corinthians 12:4, 7,9,11 NKJV
There are diversities of gifts, but the same Spirit.
 But the manifestation of the Spirit is given to each one for the profit of all:
 to another faith by the same Spirit, to another gifts of healings by the same Spirit,
 But one and the same Spirit works all these things, distributing to each one individually as He wills.
Although this passage is dealing with the gifts of the Spirit as a whole, it reveals that the Holy Spirit is involved in the ministry of healing. Jesus told His disciples that they would be His witnesses after being endued with power as a result of the Holy Spirit coming on them. Their demonstrating the works of Jesus, including healing in His name, was a part of them being His witnesses to show Jesus was alive and well. It was made possible by the ministry of the Holy Spirit. So, the oil used by the elders was symbolic of the anointing of the Holy Spirit.