string数组的初始化
一种简单的方法是string[] strTest={};
还有一种方法是string[] strTest=new string[]{""};
然后使用的时候strTest=str.Split(' ');
在oracle中也有分割字符串类型的函数substr(列名,初始位置,长度)如sub(customer,0,5)就是取列的从第一位开始的5位.
listbox和combobox中有一个int FindString(string,int count)函数,这个函数是说在listbox中或者combobox中查找出以指定字符串开头的第count个项,其返回的是index,是listbox或者combobox 的index。如:
lbxCustomer.SelectedIndex = lbxCustomer.FindString(tbxCustomerNO.Text+" ",0);
就是查找以tbxCustomerNO.Text+" "开头的第一项的index。
一种简单的方法是string[] strTest={};
还有一种方法是string[] strTest=new string[]{""};
然后使用的时候strTest=str.Split(' ');
在oracle中也有分割字符串类型的函数substr(列名,初始位置,长度)如sub(customer,0,5)就是取列的从第一位开始的5位.
listbox和combobox中有一个int FindString(string,int count)函数,这个函数是说在listbox中或者combobox中查找出以指定字符串开头的第count个项,其返回的是index,是listbox或者combobox 的index。如:
lbxCustomer.SelectedIndex = lbxCustomer.FindString(tbxCustomerNO.Text+" ",0);
就是查找以tbxCustomerNO.Text+" "开头的第一项的index。