Change browse function testcode to working code