我有以下代码在我的 WinForms 应用程序上填充我的 ListBox。
DataTable ListClass = GetDistinctRecords(LoadExceltoDatatable(plink), DistinctClass);
ListClass.Columns.Add(new DataColumn("ClassCombo", typeof(string), "Class + ClassName"));
这些值在 ListBox 中显示如下: 0007Fishing Lures
我正在尝试找出如何更改上述代码,使其看起来像这样:
(0007) Fishing Lures
或者像这样
0007 Fishing Lures
我更喜欢在值周围添加 (),但我可以解决两列之间的空间。