Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Normal
Im a little confused. You say that addresses is not an array yet above you have object[] addresses which means that it is. You also have object[] addr below which is an array of objects and attempting to reference the addresses array with it. That seems redundant to me since an object can accept anything in .NET. Wouldnt it make more sense to declare addr as an array of strings?Regardless of all that, you cant cast an entire array. You have to cast the individual elements..addr[#] = (object) addresses[#];But if the addresses array is a string you can just simply access the elements with addresses[#].ToString();
Im a little confused. You say that addresses is not an array yet above you have object[] addresses which means that it is. You also have object[] addr below which is an array of objects and attempting to reference the addresses array with it. That seems redundant to me since an object can accept anything in .NET. Wouldnt it make more sense to declare addr as an array of strings?
Regardless of all that, you cant cast an entire array. You have to cast the individual elements..
addr[#] = (object) addresses[#];
But if the addresses array is a string you can just simply access the elements with addresses[#].ToString();