as long as the URL is completely and correctly formed, there should be no problem setting the url to be attached to the Cancel button.
HOWEVER
A (cancel) button does a POST. So it's not just a "link" - it's also sending _that_ server the form details. Possibly (and probably) that server doesn't like the form, and complains (by not processing the POST). The browser, when you press Enter, does a GET.
If you let me know the URL in question I can try it out and suggest some alternatives. The most obvious alternative I can think of is to make sure the Cancel button is done as a form-field-button rather than using the built-in Cancel button.
cheers
Bruce