Helicobacter pylori isn't a direct cause for cancer. What it does is that it causes ulcer an inflammation of the stomach mucosa and these changes, persisting, may eventually lead to cancer. Any abnormal change in the body which lasts for a long time is a risk for cancer.
If you are so worried that you may have developed cancer ask your doctor to do an endoscopy and biopsy of your stomach lesions. Biopsy is the only certain way to tell if there is any cancer or not.
As for your pain, it could be many things or nothing. Can't you be a little more precise? On which side is it? Is it left? Is it in the middle of the side or more to the front? How severe is the pain? Does it go anywhere?...Can you feel it spreading or not? Is it limited to a point or is it larger? Can you feel exactly where it is or is it vague? Did you need to take an analgesic for the pain?