Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Array by getrows to listbox - date format problem
Hi Group,
As a newbie I try to develop a form where the user can build a SQL- query. By browsing this group I have learnt a lot. The result of the user built query is a recordset with 1 to 9 fields. One or more fields has date formats like "yyyy-mm-dd". As the fields, depending on the users choice, may be in different order I use the Getrows method to get an array for passing to a listbox. The trouble is that the date fields shows up in the listbox with the format "mm/dd/yyyy". I now that this problem may be solved by passing the array by additem method to the listbox. But is there a way to change the format of the dates and still using the getrows method. The code below is used to pass the array to the listbox. Some hints would be valuable. Brgds CG Rosen --------------------------------------------------------------------------------------------------------------- rsData.Open szSQL, ConnString, adOpenKeyset rcArray = rsData.GetRows With UserForm1.ListBox1 ..Clear ..ColumnCount = -1 ..Column = rcArray ..ListIndex = -1 End With |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Date format in a listbox | Excel Programming | |||
Array to Populate ListBox Problem | Excel Discussion (Misc queries) | |||
Date Format in a Userform Listbox | Excel Programming | |||
Can't assign to Array .GetRows in Excel 97 | Excel Programming | |||
Can't assign to Array .GetRows in Excel 97 | Excel Programming |