var store, address, suburb, postcode, email, webaddress;
var profiles = new Array()
	profiles[0] = new assignValues("Saddleworld", "89 Anzac Pde", "Kensington", 2033,"admin@saddleworld.com.au", "www.saddleworld.com.au");
	profiles[1] = new assignValues("Garrard's Horse & Hound", "Harold Park Raceway, under Grandstand, Ross St", "Glebe", 2037,"", "www.garrardshorseandhound.com.au");
	profiles[2] = new assignValues("Horseland", "481 Pacific Hwy", "Artarmon", 2064, "artarmon@horseland.net.au", "www.horseland.com.au");
	profiles[3] = new assignValues("Horseland Dural", "Newline Rd", "Dural", 2158, "dural@horseland.net.au", "www.horseland.com.au");
	profiles[4] = new assignValues("Saddleworld Village Court", "10 Kent Rd", "Dural", 2158, "admin@saddleworld.com.au", "www.saddleworld.com.au");
	profiles[5] = new assignValues("Horseland Tuggerah", "90 Pacific Hwy", "Tuggerah", 2259, "tuggerah@horseland.net.au", "www.horseland.com.au");
	profiles[6] = new assignValues("Lifestyple pet & prod", "3 Amy Close", "Wyong", 2259, "flyingstartdist@hotmail.com","");
	profiles[7] = new assignValues("Garrard's Horse & Hound", "Newcastle Intl Paceway, Jackson St", "Broadway", 2292,"", "www.garrardshorseandhound.com.au");
	profiles[8] = new assignValues("Horseland", "New England Highway & Johnson St", "Maitland", 2320, "maitland@horseland.net.au", "www.horseland.com.au");
	profiles[9] = new assignValues("Saddleworld Maitland", "Shop 4/522 High St", "Maitland", 2320, "admin@saddleworld.com.au", "www.saddleworld.com.au");
	profiles[10] = new assignValues("Horseland", "U2/4 Hank Rd", "Heatherbrae", 2324, "maitland@horseland.net.au", "www.horseland.com.au");
	profiles[11] = new assignValues("Furneys CRT", "78 Racecourse Rd", "Rutherford", 2330,"","");
	profiles[12] = new assignValues("Saddleworld Scone", "124 Kelley Street", "Scone", 2337, "admin@saddleworld.com.au", "www.saddleworld.com.au");
	profiles[13] = new assignValues("Everything Equine", "Shop 8, Homespace New England Hwy", "Tamworth", 2340, "everythingequinetam@bigpond.com","");
	profiles[14] = new assignValues("Horseland Tamworth", "28 Roderick St", "Tamworth", 2340, "tamworth@horseland.net.au", "www.horseland.com.au");
	profiles[15] = new assignValues("Horseland Armidale", "88 Taylor St", "Armidale", 2350, "armidale@horseland.net.au", "www.horseland.com.au");
	profiles[16] = new assignValues("Horseland Port Macquarie", "148 Lake Rd", "Port Macquarie", 2444, "portmacquarie@horseland.net.au", "www.horseland.com.au");
	profiles[17] = new assignValues("Horseland", "162 Pacific Highway", "Coffs Harbour", 2450, "coffsharbour@horseland.net.au", "www.horseland.com.au");
	profiles[18] = new assignValues("Petstock", "232 Harbour Drive", "Coffs Harbour", 2450, "coffsharbour@petstock.com.au", "www.petstock.com.au");
	profiles[19] = new assignValues("Horseland Lismore", "63 Bridge St", "LISMORE", 2480, "lismore@horseland.net.au","");
	profiles[20] = new assignValues("Woonona Petfood & Produce", "500 Princess Highway", "Woonona", 2517, "info@woononapetfoods.com.au", "www.woononapetfoods.com.au");
	profiles[21] = new assignValues("Poplar Produce", "3/6 Kingston Town Dv", "Kembla Grange", 2526,"","");
	profiles[22] = new assignValues("Horseland Wollongong", "Unit 3/60 Princes Hwy", "YALLAH", 2530, "wollongong@horseland.net.au","");
	profiles[23] = new assignValues("Petstock-Batemans Bay", "13 Kylie Cres", "Batemans Bay", 2536, "hdoberer@petstock.com.au", "www.petstock.com.au");
 	profiles[24] = new assignValues("Petstock Ulladulla", "7/233 Princes Hwy", "Ulladulla", 2539, "ulladulla@petstock.com.au", "www.petstock.com.au");
	profiles[25] = new assignValues("Equest World Saddlery", "Shop 3, John Bull Centre, Princes Hwy", "Bomaderry", 2541,"","");
	profiles[26] = new assignValues("Horseland Bega", "Unit 3/99 Bega St", "BEGA", 2550, "bega@horseland.net.au","");
	profiles[27] = new assignValues("Horseland", "Unit 8/8 Maxwell Place", "Narellan", 2567, "narellan@horseland.net.au", "www.horseland.com.au");
	profiles[28] = new assignValues("Derks", "110 Cedar Creek Rd", "Thirlmere", 2572,"","");
	profiles[29] = new assignValues("Horseland", "Lot 9 Berrima Rd", "Moss Vale", 2577, "mossvale@horseland.net.au", "www.horseland.com.au");
	profiles[30] = new assignValues("Bob Wells Saddlery", "115 Auburn Street", "Goulburn", 2580,"","");
	profiles[31] = new assignValues("Saddleworld-Phillip,ACT", "5 Townsend St", "Phillip", 2606, "admin@saddleworld.com.au", "www.saddleworld.com.au");
	profiles[32] = new assignValues("Horseland", "14 Ipswich St", "Fyshwick", 2609, "fyshwick@horseland.net.au", "www.horseland.com.au");
	profiles[33] = new assignValues("Horseland Belconnen", "21 Rae St", "Belconnen", 2617, "belconnen@horseland.net.au", "www.horseland.com.au");
	profiles[34] = new assignValues("Horseland", "592 Hume St", "Albury", 2641, "albury@horseland.net.au", "www.horseland.com.au");
	profiles[35] = new assignValues("Petstock-Albury", "334 Wagga Rd", "Lavington", 2641, "albury@petstock.com.au", "albury@petstock.com.au");
	profiles[36] = new assignValues("Animal House-Provet Riverina", "12 Blaxland Rd", "Wagga Wagga", 2650, "www.provet.net.au","");
	profiles[37] = new assignValues("Horseland Wagga Wagga","1/381 Edward St",	"Wagga Wagga",2650,"waggawagga@horseland.net.au","www.horseland.com.au");
	profiles[38] = new assignValues("South West Stockfeeds","11 Moorong St","Wagga Wagga",2650,"","");
	profiles[39] = new assignValues("Horseland Richmond", "22 Windsor St", "Richmond", 2753, "richmond@horseland.net.au", "www.horseland.com.au");
	profiles[40] = new assignValues("Sydney Equestrian Supplies", "5 Post Office Rd", "Ebenezer", 2756, "", "www.sydneyequestriansupplies.com.au");
	profiles[41] = new assignValues("Bedwells Feed Barn", "11 Keppell St", "Bathurst", 2795, "", "");
	profiles[42] = new assignValues("Fish & Sons Rural`", "1 Lambert St", "Bathurst", 2795, "", "");
	profiles[43] = new assignValues("Horseland Orange", "20 Peisley St", "ORANGE  ", 2800, "orange@horseland.net.au", "");
	profiles[44] = new assignValues("Horseland Dubbo", "124 Erskine St", "Dubbo", 2830, "dubbo@horseland.net.au", "www.horseland.com.au");
	profiles[45] = new assignValues("Petstock", "431 Old Geelong Rd", "Hoppers Crossing", 3029, "hoppers@petstock.com.au", "www.petstock.com.au");
	profiles[46] = new assignValues("Ascotvale Saddlery Saddleworld", "540 Racecourse Rd", "Flemington", 3031, "", "www.ascotsaddlery.com.au");
	profiles[47] = new assignValues("Horseland ", "1/88 Cooper St", "Epping", 3076, "epping@horseland.net.au", "www.horseland.com.au");
	profiles[48] = new assignValues("Horseland ", "87 Main St", "Greensborough", 3088, "", "www.horseland.com.au");
	profiles[49] = new assignValues("Saddle-Up Saddleworld", "Shop 6 Chirnside Homemaker Ctr 282 Maroondah Hwy", "Chirnside Park", 3116, "admin@saddleworld.com.au", "www.saddleworld.com.au");
	profiles[50] = new assignValues("Horseland", "158 Maroondah Hwy", "Ringwood", 3134, "ringwood@horseland.net.au", "www.horseland.com.au");
	profiles[51] = new assignValues("Croydon Pet & Produce", "66 Maroondah Hwy", "Croydon", 3136, "", "");
	profiles[52] = new assignValues("Horseland", "476 Maroondah Hwy", "Lilydale", 3140, "lilydale@horseland.net.au", "lilydale@horseland.net.au");
	profiles[53] = new assignValues("Petstock", "457 Maroondah Hwy", "Lilydale", 3140, "lilydale@petstock.com.au", "www.petstock.com.au");
	profiles[54] = new assignValues("Dandenong Farm Supplies", "Factory 5/155 Greens Rd", "Dandenong", 3175, "", "");
        profiles[55] = new assignValues("Horseland Dandenong", "153 Lonsdale St", "Dandenong", 3175, "dandenong@horseland.net.au", "www.horseland.com.au");
	profiles[56] = new assignValues("Petstock", "202 Sladen St", "Cranbourne", 3199, "", "www.petstock.com.au");
	profiles[57] = new assignValues("Racing Supplies", "Warehouse 7 41 Sabre Dv", "Port Melbourne", 3207, "", "");
	profiles[58] = new assignValues("Petstock Corio", "290 Princes Hwy", "Corio", 3214, "Corio@petstock.com.au", "www.petstock.com.au");
	profiles[59] = new assignValues("Petstock", "150 Barwon Head Rd", "Belmont", 3216, "geelong@petstock.com.au", "www.petstock.com.au");
	profiles[60] = new assignValues("Horseland", "145 Fyans Rd", "Geelong", 3220, "geelong@horseland.net.au", "www.horseland.com.au");
	profiles[61] = new assignValues("Petstock Sth Geelong", "82 Fyans Rd", "Sth Geelong", 3220, "geelongcity@petstock.com.au", "www.petstock.com.au");
	profiles[62] = new assignValues("Petstock", "65 Bromfield St", "Colac", 3250, "colac2@petstock.com.au", "www.petstock.com.au");
	profiles[63] = new assignValues("Country Link Rural Supp", "2-6 Mill Rd", "Lara", 3262, "", "");
	profiles[64] = new assignValues("Horseland Warrnambool", "203 Lava St", "WARRNAMBOOL  ", 3280, "warrnambool@horseland.net.au", "");
	profiles[65] = new assignValues("Warrnambool Co-op ", "259 Timor St", "Warrnambool", 3280, "", "");
	profiles[66] = new assignValues("Hamilton Produce", "295 Coleraine Rd", "Hamilton", 3300, "", "");
	profiles[67] = new assignValues("Melton Saddlery", "79-81 Unitt St", "Melton", 3337, "", "");
	profiles[68] = new assignValues("Petstock Melton", "77 High St", "Melton", 3337, "nallan@petstock.com.au", "www.petstock.com.au");
	profiles[69] = new assignValues("Petstock", "909 Latrobe St", "Ballarat", 3350, "joany@petstock.com.au", "www.petstock.com.au");
	profiles[70] = new assignValues("Saddleworld Ballarat", "37 Armstrong St North", "Ballarat", 3350, "", "www.saddleworld.com.au");
	profiles[71] = new assignValues("Petstock", "49-51 Urquhart St", "Horsham", 3400, "horsham@petstock.com.au", "www.petstock.com.au");
	profiles[72] = new assignValues("Horseland", "3/57-59 Horne St", "Sunbury", 3422, "sunbury@horseland.net.au", "www.horseland.com.au");
	profiles[73] = new assignValues("Petstock Gisborne", "20 Robertson Rd", "Gisborne", 3437, "gisborne@petstock.com.au", "www.petstock.com.au");
	profiles[74] = new assignValues("RS Perry & Sons", "5 Market St", "Kyneton", 3444, "rsperry@bigpond.net.au", "");
	profiles[75] = new assignValues("Petstock", "73 Forest St", "Castlemaine", 3450, "castlemain@petstock.com.au", "www.petstock.com.au");
	profiles[76] = new assignValues("Horseland", "71 Orange Ave", "Mildura", 3500, "mildura@horseland.net.au", "www.horseland.com.au");
	profiles[77] = new assignValues("Petstock Mildura", "2/751 Fifteenth St", "Mildura", 3500, "mildura@petstock.com.au", "www.petstock.com.au");
	profiles[78] = new assignValues("Garrard's Horse & Hound", "c/- Lords Paceway, McIvor Hwy", "Bendigo", 3550, "", "www.garrardshorseandhound.com.au");
	profiles[79] = new assignValues("Horseland", "201 Breen St", "Bendigo", 3550, "bendigo@horseland.net.au", "www.horseland.com.au");
	profiles[80] = new assignValues("Petstock", "106 Hattam St", "Bendigo", 3550, "bendigo@petstock.com.au", "www.petstock.com.au");
	profiles[81] = new assignValues("Horseland Ballarat", "217 Mair St", "Ballarat", 3559, "ballarat@horseland.net.au", "www.horseland.com.au");
	profiles[82] = new assignValues("Horseland", "26 Benalla Rd", "Shepparton", 3630, "shepparton@horseland.net.au", "www.horseland.com.au");
	profiles[83] = new assignValues("Petstock Shepparton", "57 Benalla Rd", "Shepparton", 3630, "Shepparton@petstock.com.au", "www.petstock.com.au");
	profiles[84] = new assignValues("Saddleworld ", "210 Benalla Rd", "Shepparton", 3630, "admin@saddleworld.com.au", "www.saddleworld.com.au");
	profiles[85] = new assignValues("Bucklands Saddleworld", "29 Ely St", "Wangaratta", 3677, "", "");
        profiles[86] = new assignValues("South Morang Petstock", "441 McDonalds Rd", "South Morang", 3752, "", "www.petstock.com.au");
	profiles[87] = new assignValues("Yan Yean Stock Feeds", "Cnr Plenty & Donny Brook Rds", "Yan Yean", 3755, "", "");
	profiles[88] = new assignValues("Saddleworld", "2 Willowmavin Rd", "Kilmore", 3764, "admin@saddleworld.com.au", "www.saddleworld.com.au");
	profiles[89] = new assignValues("Glen Valley Produce", "1/2 Armstrong Gr", "Yarra Glen", 3775, "snichols@alphalink.com.au", "www.glenvalleyproduce.com.au");
	profiles[90] = new assignValues("Yarra Junction Produce", "2434 Warburton Hwy", "Yarra Junction", 3797, "", "");
	profiles[91] = new assignValues("Horseland ", "420 Princes Hwy", "Narre Warren", 3804, "narrewarren@horseland.net.au", "www.horseland.com.au");
	profiles[92] = new assignValues("Narre Warren Produce", "Unit 6/36 Lauderdale Rd", "Narre Warren", 3805, "", "");
	profiles[93] = new assignValues("Officer Grain Store", "431 Princes Hwy", "Officer", 3809, "", "");
	profiles[94] = new assignValues("Pakenham Produce ", "62 Station St", "Pakenham", 3810, "", "");
	profiles[95] = new assignValues("Horseland", "Unit 1/183 Queen St", "Warragul", 3820, "warragul@horseland.net.au", "www.horseland.com.au");
	profiles[96] = new assignValues("Horseland", "72 Argyle St", "Traralgon", 3844, "traralgon@horseland.net.au", "www.horseland.com.au");
	profiles[97] = new assignValues("The Stable Door", "264 York St", "Sale", 3860, "", "http://stabledoor.com.au");
	profiles[98] = new assignValues("Hastings Produce", "2083 Frankston/Flinders Rd", "Hastings", 3915, "", "");
	profiles[99] = new assignValues("Petstock", "Unit 5 1138-1140 Nepean Hwy ", "Mornington", 3931, "mornington@petstock.com.au", "www.petstock.com.au");
	profiles[100] = new assignValues("Farm Hand", "224 High St", "Cranbourne", 3977,"", "");	
	profiles[101] = new assignValues("Horsepower", "1495 Sth Gippsland Hwy ", "Cranbourne", 3977, "horsepower@horsepower.com.au", "www.horsepower.com.au");
        profiles[102] = new assignValues("Horseland ", "10/205 Tyabb Rd", "Mornington", 3981,"mornington@horseland.net.au", "www.horseland.com.au");
        profiles[103] = new assignValues("Mornington Stockfeed", "98 Wait Rd", "Mornington", 3981, "", "");
        profiles[104] = new assignValues("Bernie's Produce", "Shed 1, QBBS Auction Centre, Hampton St", "Doomben", 4007, " ", "");
        profiles[105] = new assignValues("Garrards Horse & Hound", "Albion Park Raceway, Amy St", "Albion", 4007, "", "www.garrardshorseandhound.com.au");
        profiles[106] = new assignValues("Horseland Jindalee", "182 Sinnamon Rd", "Jindalee", 4074, "jindalee@horseland.net.au", "www.horseland.com.au");
        profiles[107] = new assignValues("Furneys Stockfeeds", "594 Boundary St", "Archerfield", 4103, "", "");
        profiles[108] = new assignValues("Aitken Saddlery", "20 Kingston Rd", "Underwood", 4119, "enquiries@aitkenssaddlery.com.au", "www.aitkenssaddlery.com.au");
        profiles[109] = new assignValues("Horseland ", "22 Kingston Rd", "Underwood", 4119, "underwood@horseland.net.au", "www.horseland.com.au");
        profiles[110] = new assignValues("Capalaba Produce", "3211 Old Cleveland Rd", "Capalaba", 4157, "", "");
	profiles[111] = new assignValues("Saddleworld ", "7/29 Logan River Rd", "Beenleigh", 4207, "", "www.saddleworld.com.au");
        profiles[112] = new assignValues("Everything Equine", " Shop 6B 5 Cottonwood Place", "Oxenford", 4210, "everythingequineoxenford@yahoo.com.au", "");
        profiles[113] = new assignValues("Horseland Gold Coast", "1/90 Spencer Rd", "Nerang", 4211, "nerang@horseland.net.au", "www.horseland.com.au");
        profiles[114] = new assignValues("Bernies Pet & Produce", "31 Upton St", "Bundall", 4217, "", "");
        profiles[115] = new assignValues("Garrards Horse & Hound", "Unit 4/1 Ken Russel Court", "Bundall", 4217, "", "www.garrardshorseandhound.com.au");
        profiles[116] = new assignValues("Beaudesert Rural Supplies", "157 Helen St", "Beaudesert", 4285, "", "");
	profiles[117] = new assignValues("Beaudesert Stock Feeds", "58 William St", "Beaudesert", 4285, "", "");
	profiles[118] = new assignValues("Elders", "28 Telemon St", "Beaudesert", 4285, "", "www.elders.com.au");
        profiles[119] = new assignValues("Horseland Ipswich", "1 Pine Street", "Ipswich", 4305, "ipswich@horseland.net.au", "www.horseland.com.au");
        profiles[120] = new assignValues("Fernvale Produce", "1452 Brisbane Valley Hwy", "Fernvale", 4306, "", "");
        profiles[121] = new assignValues("Edwards Saddleworld", "152 Taylor St", "Toowoomba", 4350, "edwards.saddleworld@enter.net.au", "");
        profiles[122] = new assignValues("Elders", "397 South St", "Toowoomba", 4350, "", "www.elders.com.au");
        profiles[123] = new assignValues("Horseland Toowoomba", "4/900 Ruthven St", "TOOWOOMBA  ", 4350, "toowoomba@horseland.net.au", "");
        profiles[124] = new assignValues("Queensland Produce Distributors", "222 McDougall St", "Toowoomba",4350,"", "www.queenslandproduce.com.au");
        profiles[125] = new assignValues("Horseland Strathpined", "Shop 2/640 Gympie Rd", "Lawnton",4501, "lawnton@horseland.com.au", "www.horseland.com.au");
	profiles[126] = new assignValues("Petstock", "2-4 Strahvale Crt", "Caboolture", 4510, "caboolture@petstock.com.au", "www.petstock.com.au");
        profiles[127] = new assignValues("Sandale Saddlery", "15 Glenview Rd", "Palmview", 4553, "sandale7@bigpond.com ", "");
        profiles[128] = new assignValues("Horseland Sunshine Coast", "Mons Rd", "Forest Glen", 4556, "forestglen@horseland.net.au", "www.horseland.com.au");
        profiles[129] = new assignValues("Horseland Bundaberg", "13 Electra St", "BUNDABERG   ", 4670, "bundaberg@horseland.net.au", "");
        profiles[130] = new assignValues("Healthy Horses", "102 William St", "Rockhampton", 4700, "", "");
        profiles[131] = new assignValues("Horseland Rockhampton", "110 Gladstone Road", "ROCKHAMPTON ", 4700, "rockhampton@horseland.net.au", "");
        profiles[132] = new assignValues("Horseland Mackay", "321 Nebo Rd", "Mackay", 4740, "mackay@horseland.net.au", "");
	profiles[133] = new assignValues("Garrards Horse & Hound", "38 Carmel St", "Garbutt,Townsville", 4810, "", "www.garrardshorseandhound.com.au");
        profiles[134] = new assignValues("Equine Solutions", "59 Bowen Rd", "Townsville", 4812, "", "");
        profiles[135] = new assignValues("Horseland ", "205 Ross River Rd", "Townsville", 4814,"townsville@horseland.net.au", "www.horseland.com.au");
        profiles[136] = new assignValues("Horseland Adelaide", "291 Main North Rd", "ENFIELD   ", 5085, "adelaide@horseland.net.au", "");
        profiles[137] = new assignValues("Sanders Grain & Fodder", "Cnr 22nd & 23rd St", "Gawler", 5118, "", "");
        profiles[138] = new assignValues("Horseland Mount Barker", "PO Box 629", "LITTLEHAMPTON", 5250, "mtbarker@horseland.net.au", "");
        profiles[139] = new assignValues("Horseland Mount Barker", "214 Commercial Street East", "MT GAMBIER ", 5290, "mtgambier@horseland.net.au", "");
        profiles[140] = new assignValues("Europa Saddlery", "206 Gt Eastern Hwy", "Midland", 6056, "sales@europasaddlery.com", "www.europasaddlery.com");
        profiles[141] = new assignValues("Horseland Midland", "212 Great Eastern Hwy", "Midland", 6056, "midland@horseland.net.au", "www.horseland.com.au");
        profiles[142] = new assignValues("The Farm Shop", "32 Clayton St", "Bellevue", 6056, "midland@thefarmshop.com.au", "");
        profiles[143] = new assignValues("City Live Stock", "727a Gnangara Rd", "Lexia", 6065, "", "");
        profiles[144] = new assignValues("Wanneroo Stockfeeds", "Unit 1/73 Paramount Dv", "Wangara", 6065, "", "");
        profiles[145] = new assignValues("Bio John", "13 Camden St", "Belmont", 6104, "", "www.bio-john.com.au");
        profiles[146] = new assignValues("Europa Saddlery", "1871 Albany Hwy", "Maddington", 6109,"", "www.europasaddlery.com");
        profiles[147] = new assignValues("Horseland Maddington", "1868 Albany Hwy", "Maddington", 6111, "maddington@horseland.net.au", "www.horseland.com.au");
        profiles[148] = new assignValues("Norwest Stock Feeders", "426 Robinson St", "Carnarvon East", 6701, "norwestpetmeats@bigpond.com", "");
        profiles[149] = new assignValues("Pinjarra Traders", "47 McLarty Rd", "Pinjarra", 6208, "pinjarratraders@aol.com", "");
        profiles[150] = new assignValues("Mandurah Stockfeeds", "114 Park Rd", "Mandurah", 6210, "", "");
	profiles[151] = new assignValues("Petstock Mandurah", "15 Rouse Rd", "Mandurah", 6210, "mandurah@petstock.com.au", "www.petstock.com.au");
        profiles[152] = new assignValues("Picton Produce", "Lot 3 South Western Hwy", "Picton Junction", 6229, "", "");
        profiles[153] = new assignValues("Europa Saddlery", "140 Blair St", "Bunbury", 6230, "", "www.europasaddlery.com");
        profiles[154] = new assignValues("The Feed Bin Pinjarra", "Lot 31, South Western Highway", "Pinjarra", 6208, "robertmac@iinet.net.au", "");
        profiles[155] = new assignValues("Wight & Emmett", "33 Wellington St", "Bunbury", 6230, "", "");
        profiles[156] = new assignValues("Woorree Stockfeeds", "21 Dayana Dv", "Woorree", 6530, "suttonwd@optusnet.com.au", "");
        profiles[157] = new assignValues("Landmark Narrogin", "20 Federal St", "Narrogin", 6312, "", "www.landmark.com.au");
        profiles[158] = new assignValues("GSR Rural Services", "Lowood Rd", "Mt Barker", 6324, "gsruralservices@bigpond.com", "");
        profiles[159] = new assignValues("Albany Horseworld", "138 Chesterpass Rd", "Albany ", 6330, "", "");
        profiles[160] = new assignValues("Albany Stockfeeds", "496 Albany Hwy", "Albany ", 6330, "", "");
        profiles[161] = new assignValues("Europa Saddlery", "209 Chesterpass Rd", "Albany ", 6330, "sales@europasaddlery.com", "www.europasaddlery.com");
        profiles[162] = new assignValues("Loffs Feed & Saddlery", "72 Norseman Rd", "Esperance", 6450, "", "");
        profiles[163] = new assignValues("Stockyard Stock Supplies", "91 Pass St", "Geraldton", 6530, "", "");
        profiles[164] = new assignValues("Horseland", "430 Newcastle St", "Perth", 6988, "perth@horseland.net.au", "www.horseland.com.au");
        profiles[165] = new assignValues("Horseland Hobart", "254 Liverpool St", "Hobart", 7000, "hobart@horseland.net.au", "www.horseland.com.au");
        profiles[166] = new assignValues("Roberts", "2 Collins St", "Hobart", 7000, "info@robertsltd.com.au", "www.robertsltd.com.au");
        profiles[167] = new assignValues("Roberts", "327 Midlands Hwy", "Bridgewater", 7030, "info@robertsltd.com.au", "www.robertsltd.com.au");
        profiles[168] = new assignValues("Roberts", "177 Main Rd", "Huonville", 7109, "info@robertsltd.com.au", "www.robertsltd.com.au");
        profiles[169] = new assignValues("Horseland Launceston", "149 Talbot Rd", "Kings Meadow", 7250, "kingsmeadow@horseland.net.au", "www.horseland.com.au");
        profiles[170] = new assignValues("Roberts", "444 Westbury Rd", "Prospect", 7250, "info@robertsltd.com.au", "www.robertsltd.com.au");
	profiles[171] = new assignValues("Saddleworld", "77-79 Elizabeth St", "Launceston", 7250, "saddleworld@vision.net.au", "www.saddleworld.com.au");
        profiles[172] = new assignValues("Devonport Saddlery", "50 Formby Rd", "Devonport", 7310, "saddlery@keypoint.com.au", "");
        profiles[173] = new assignValues("Roberts", "1-3 Formby Rd", "Devonport", 7310, "info@robertsltd.com.au", "www.robertsltd.com.au");
        profiles[174] = new assignValues("Roberts", "38 Alexandria Rd", "Ulverstone", 7315, "info@robertsltd.com.au", "www.robertsltd.com.au");
        profiles[175] = new assignValues("Garrads", "27 Guthrie St", "Osbourne Park", 6017, "", "");	
	profiles[176] = new assignValues("Cepa Farm Supplies", "4-10 Stanley St", "Bendigo", 3550, "cepa@netcon.net.au", "www.cepa.com.au");

function assignValues(store, address, suburb, postcode, email, webaddress)
{
	this.store = store;
	this.address = address;
	this.suburb = suburb;
	this.postcode = postcode;
	this.email = email;
	this.webaddress = webaddress;
	return this;
}

function clear()
{
		
	document.frm.txt1.value = "";
	document.frm.txt2.value = "";
	document.frm.txt3.value = "";
	document.frm.txt4.value = "";
	this.store = "";
	this.address = "";
	this.suburb = "";
	this.postcode = "";
	this.email = "";
	this.webaddress = "";
}
function OnAdd()
{
	var txtValue1 = document.frm.txt1.value;
	var txtValue2 = document.frm.txt2.value;
	var txtValue3 = document.frm.txt3.value;
	var txtValue4 = document.frm.txt4.value;
	var tb2 = document.getElementById("tblNames");
	removeChildNodes(tb2);
if(txtValue1.length == 0)
	{
		alert("Please Enter a Value");
		frm.txt1.focus();
		return false;
		
	}
	if(txtValue2.length == 0)
	{
		alert("Please Enter a Value");
		frm.txt2.focus();
		return false;
		
	}
	if(txtValue3.length == 0)
	{
		alert("Please Enter a Value");
		frm.txt3.focus();
		return false;
		
	}
	if(txtValue4.length == 0)
	{
		alert("Please Enter a Value");
		frm.txt4.focus();
		return false;
		
	}
	
	var getVal = txtValue1+""+txtValue2+""+txtValue3+""+txtValue4;
	
	if(isNaN(getVal))
	{
		alert("Please Enter Only Numbers");
		return false;
	}
	else
	{
		
		var txtVal = parseInt(getVal);
		//--------------
		var concatstr = "";
		var no=0, leastno=0, biggestno=0;
		for(var i=1; i<getVal.length; i++)
		{
			concatstr += "0";
		}
		no = parseInt(1+concatstr);
		leastno = parseInt(txtValue1)*no;
		biggestno = (parseInt(txtValue1)+1)*no;
		//alert(leastno+" "+biggestno);
		//---------------->
		
		var tbl = null;
		var row = null;
		var cell = null;
		var oTBody = null;
		var tbl = null; 

		tbl = document.getElementById("tblNames");
		
		
		for(var r=0; r<profiles.length; r++)
		{
		
			for(var c=0; c<profiles.length-1; c++)
			{
			
				if(profiles[c].postcode >profiles[c+1].postcode)
				{
					
					var temp2 = profiles[c].store;
					profiles[c].store = profiles[c+1].store;
					profiles[c+1].store = temp2;
					
					var temp3 = profiles[c].address;
					profiles[c].address = profiles[c+1].address;
					profiles[c+1].address = temp3;
					
					var temp4 = profiles[c].suburb;
					profiles[c].suburb = profiles[c+1].suburb;
					profiles[c+1].suburb= temp4;
					
					var temp5 = profiles[c].postcode;
					profiles[c].postcode = profiles[c+1].postcode;
					profiles[c+1].postcode = temp5;
					
					var temp6 = profiles[c].email;
					profiles[c].email = profiles[c+1].email;
					profiles[c+1].email = temp6;
					
					var temp7 = profiles[c].webaddress;
					profiles[c].webaddress = profiles[c+1].webaddress;
					profiles[c+1].webaddress = temp7;
				
				}
			}
		}
		var position=0, no=0;
		var sa = 0, sb=0;
		for(var i=0; i<profiles.length; i++)
		{
			//alert(profiles[i]);
			if(profiles[i].postcode == txtVal)
			{
				position = i;
				break;
			}
			if(profiles[i].postcode >txtVal)
			{
				sa = i;
				sb = i-1;
				var searchafter=0, searchbefore=0;
				searchafter = profiles[sa].postcode - txtVal;
				searchbefore = txtVal - profiles[sb].postcode;
				var search =0;
				if(searchbefore > searchafter)
					{
						position = sa;
						
					}
					else
					{
						position = sb;
						
					}
				break;
			}
		}
		//alert(txtVal +"\t"+ position);
		
		var x = position; y = position;
		
		//var biggest=0;
		//biggest = (txtValue1*1000)+(1000-1);
		
		for(var r=0; r<profiles.length; r++)
		{
				
				
				if(	x <=profiles.length-1)
				{
					if( (profiles[x].postcode  > leastno) && (profiles[x].postcode < biggestno)) 
					{
						
					
				
				row = document.createElement("tr");
										
				
				cell = document.createElement("td");
				cell.innerHTML = " ";
				row.appendChild(cell);
						
				cell = document.createElement("td");
				cell.innerHTML  = profiles[x].store;
				row.appendChild(cell);
				
				cell = document.createElement("td");
				cell.innerHTML  = profiles[x].address;
				row.appendChild(cell);
				
				cell = document.createElement("td");
				cell.innerHTML  = profiles[x].suburb;
				row.appendChild(cell);
				
				cell = document.createElement("td");
				cell.innerHTML  = profiles[x].postcode;
				row.appendChild(cell);
				
				cell = document.createElement("td");
				cell.innerHTML  = "<a href=mailto:" + profiles[x].email+">" + profiles[x].email;
				row.appendChild(cell);
				
				cell = document.createElement("td");
				cell.innerHTML  = "<a href=http://"+profiles[x].webaddress+">"+profiles[x].webaddress+"</a>";
				row.appendChild(cell);
				tbl.appendChild(row);
					}
				x++;
				}
								
				
				if(	y >0)
				{
					y--;                                                                                                  
					if( (profiles[y].postcode  > leastno) && (profiles[y].postcode < biggestno)) 
					{
						
					
				
					//alert(profiles[y].postcode);
					
					
					row = document.createElement("tr");
					
					
					cell = document.createElement("td");
					cell.innerHTML = " ";
					row.appendChild(cell);
					
					cell = document.createElement("td");
					cell.innerHTML = profiles[y].store;
					row.appendChild(cell);
					cell = document.createElement("td");
					cell.innerHTML = profiles[y].address;
					row.appendChild(cell);
					
					cell = document.createElement("td");
					cell.innerHTML = profiles[y].suburb;
					row.appendChild(cell);
					
					cell = document.createElement("td");
					cell.innerHTML = profiles[y].postcode;
					row.appendChild(cell);
					
					cell = document.createElement("td");
					cell.innerHTML = "<a href=mailto:" + profiles[y].email+">" + profiles[y].email;
					row.appendChild(cell);
					
					cell = document.createElement("td");
					cell.innerHTML  = "<a href=http://"+profiles[y].webaddress+">"+profiles[y].webaddress+"</a>";
					row.appendChild(cell);
					tbl.appendChild(row);
					}
					
				}	
				//------------
				/*if(y == 0 && x == profiles.length-1)
				{
					alert(profiles[r].postcode);
					break;
				}*/
			}
			x = 0;
			y = 0;
	}
	tbl = null;
	row = null;
	cell = null;
	oTBody = null;
	tbl = null;
	x = 0;
	y = 0;
	
}

function removeChildNodes(ctrl)
{
	while (ctrl.childNodes[0])
	{
		ctrl.removeChild(ctrl.childNodes[0]);
	}
}
