i tried converting this code from c#
a += (uint)(url[k + 0] + (url[k + 1] << 8) + (url[k + 2] << 16) + (url[k + 3] << 24));
http://msdn.microsoft.com/en-us/library/7haw1dex%28v=vs.71%29.aspx be sure that you use supported types.