Recent content by LEXCERM

  1. L

    QBE Grid Query: Search for specific date

    Hi Grumm, Your last reply got me thinking. Did a little research and came up with this solution which I place in the criteria part of the query:- Like IIf(IsNull([Forms]![frm_DataMart]![cmbDate]),"*",[Forms]![frm_DataMart]![cmbDate]) This seems to work! Thanks again for your time. Much...
  2. L

    QBE Grid Query: Search for specific date

    Hi Grumm and thanks for the feedback. :) Yes, I am aware of the "like" capabilities, however, if the particular field is left blank, then no records are returned at all. For example, I have tried this: Like [Forms]![frm_DataMart]![cmbDate] Or Is Null ... but no records are returned. The...
  3. L

    QBE Grid Query: Search for specific date

    Hi all, Currently, I have a query which is set-up for searching on multiple fields on a form. I am having an issue with finding a specific date within a month. For example, the query field is as follows:- Field: myDate: Day([ID_Date]) Criteria: Like "*" & [Forms]![frm_DataMart]![cmbDate] &...
  4. L

    Comma-delimted text values to ListBox

    [SOLVED] Comma-delimIted text values to ListBox Found the solution: myArray = Split(Forms![frm_NewCode]![txt_CodeString], ",") For i = LBound(myArray) To UBound(myArray) For ii = 0 To Me.lstClientCodes.ListCount - 1 If Me.lstClientCodes.Column(0, ii) =...
  5. L

    Comma-delimted text values to ListBox

    Hi all, I have the following code on the "on-click" event of a listbox which populates a textbox:- Dim strSelected As String Dim varItem As Variant With Me.lstClientCodes For Each varItem In .ItemsSelected strSelected = strSelected & "," & .ItemData(varItem) Next varItem...
  6. L

    Distributing Front-End

    Thanks for the links arnelgp. :)
  7. L

    Distributing Front-End

    Morning all. Can someone please point me in the right direction or advise. I have a split DB and multiple FE's for approx 15 users. When I update the FE, I do a quick copy/paste replace and rename the files accordingly. This doesn't take long, but I was wondering if there was a more...
  8. L

    DoCmd.Output

    Hi all. I am currently using the following line to output data to Excel:- DoCmd.OutputTo acOutputQuery, "qry_OutstandingRecs", acFormatXLSX This will open a dialog box and you select a path/directory for saving. Is there a way that you can capture the name of the file/path in a variable then...
  9. L

    Collections and Bubble Sort (maybe)

    Hi gemma-the-husky, Thanks for replying. Yeah, arnelgp said pretty much the same. I chopped and changed the code so many times, I lost site of the declarations etc. Schoolboy error on my part. Thanks again. :)
  10. L

    Collections and Bubble Sort (maybe)

    Thank you so much arnelgp, have now got it working. Have a great day! :)
  11. L

    Collections and Bubble Sort (maybe)

    Hi arnelgp, Thanks for replying. As suggested, I am calling the BubbleSort straight after the split, but still get the Type Mismatch error on this line:- Dim strTemp As String Dim i As Long Dim j As Long Dim lngMin As Long Dim lngMax As Long lngMin = LBound(arr) lngMax = UBound(arr) For i =...
  12. L

    Collections and Bubble Sort (maybe)

    Hi all. I have found the following piece of code which finds dupes in a comma delimited string and removes them. This works faultlesly:- Dim sString As String Dim MyAr As Variant Dim Col As New Collection Dim itm, i sString = Me.txt_CodeString MyAr = Split(sString, ",") For i = LBound(MyAr)...
  13. L

    Enhancing ADO import query

    Thanks Minty and Galaxiom for your replies and apologies for not getting back to you sooner. Read both your posts with interest. Due to laggy connectivity issues, we're going to schedule output files from SQL each morning. This will only happen once a day and these files will be imported just...
  14. L

    Enhancing ADO import query

    Thanks for replying Minty. I have worked with Stored Procedures in a previous life lol (last job where our sql server man would assist me on this), but it's different now. At present, I am only able to connect to the SQL tables as per code above and import the data as shown.
  15. L

    Enhancing ADO import query

    Morning all, I have the following snippet of code which connects to our sqlServer via ADO:- Dim conn As ADODB.Connection Dim rs As ADODB.Recordset Dim sConnString As String sConnString = "Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security " & _...
Top Bottom