在C#中REDIM preserve? [英] Redim Preserve in C#?

查看:873
本文介绍了在C#中REDIM preserve?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我感到非常震惊今天C#不支持动态大小的数组找出来。那么如何做习惯使用的 VB.NET开发。 COM / EN-US /库/ w8k3cys2.aspx>使用ReDim preserve 处理这在C#?

I was shocked to find out today that C# does not support dynamic sized arrays. How then does a VB.NET developer used to using ReDim Preserve deal with this in C#?

在函数的开始,我不知道该数组上限的。这取决于从数据库返回的行。

At the beginning of the function I am not sure of the upper bound of the array. This depends on the rows returned from the database.

推荐答案

使用的ArrayList或仿制,而不是

Use ArrayLists or Generics instead

这篇关于在C#中REDIM preserve?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆