Sayyiduna Abdullah bin Umar (may Allah be pleased with them both) narrates that the Messenger of Allah (peace and blessings be upon him) said: "Whoever swears by other than Allah..." The Prophet (peace and blessings be upon him) spoke very harshly about this.