Working Code till MGI Reference Number