Severe pain could be due to anal fissure or hemorrhoids.How much dulphalac and in what quantity have you been consuming?
Hard stools with severe pain points towards anal fissure. Most small anal fissures heal spontaneously if stool passage is smooth. Do you see blood along with stools?
Next Steps
Since your stools are hard you should try stronger laxatives + stool softener and drink plenty of water, also you should modify your diet to a fiber rich diet. For more information you can connect directly.