Prevent you from getting cancer in the first place? You can't prevent anyone from getting cancer. You can detect cancer early, then use Chemotherapy and surgery (which costs money by the way) to irradiate the cancer, then monitor the site of the cancer with more tests(expensive). Thats as far as we can go with modern medicine.
But what if you discovered the cancer in later stages that are fatal? Then you go through the rounds of Chemotherapy etc and eventually die. Purely looking at it from a financial standpoint, you just saved the system money by not incurring end of life care. No more joint/hip replacement. No stents. No annual prostate exams/mamograms. No monthly checkups. No expensive drugs.
You are overgeneralizing. There are at a minimum, hundreds, if not thousands, of types of cancer. Some are very treatable, some are not. We can substantially reduce the risk of developing specific cancers by providing adequate preventative care. The problem here is that you are comparing apples to oranges.
Preventative care implies seeing a doctor for regular physical exams. Healthy eating, physical fitness, limited alcohol consumption, and not smoking are all preventative measures. Routine blood tests to monitor things like cholesterol are also important. For women, at least one cancer can be completely prevented via vaccine (cervical cancer).
Does preventative care guarantee an individual won't get cancer? No, I'm a living testament to that, but that doesn't change the fact that certain behaviors greatly increase risk.
By seeing a doctor regularly, they may recommend you get early detection screenings. If a society is going to bother trying to cure cancer, then early detection reduces the societies costs. Cancer is easier, and thus cheaper, to treat when it is detected early. Simply put, early detection is not the same as prevention.
Your position seems to be entirely about saving money, which is fine. However, there is really no reason for us to invest any resources in trying to treat illnesses like cancer if our only concern is money. The cost for treating these illnesses is substantial. There are also huge investments in research, both in terms of time and manpower. If you are dedicated time/money to cure cancer, that means those resources can't be used elsewhere. Individuals who survive cancer will inevitably take more financial resources out of the system than they can put in. So the answer to your question is very simple: it's called progress. We treat it because we can.
Note that I do not believe end of life care should stay the same way it does now. That said, this is a very dicey area. People are afraid of dying, which is why so much money is spent on extreme treatments near the end of life. Ultimately, this is an area where I feel that the individuals involved must be allowed to remain in control of these decisions. I certainly don't want the government involved in anyway. I'm in mental health counseling, and I personally believe that we need more counselors who are interested in working with the seriously ill. Unfortunately there is a critical shortage in this area. End of Life Individual and Family Counseling may help to ease some of the financial burden you've described, but then again, it may not.