В вашем компоненте i.e угловой код js:
function getthefile (){ window.location.href='http://localhost:1036/CourseRegConfirm/getfile'; };