Search results

  1. K

    Sql for date problem

    Re: Sql for date problem (SOLVED) Ok I solved my code problem as following: Set rs = cdb2.OpenRecordset("SELECT * FROM tblSpy WHERE ID=" & Me.cbxItems.Value & " And [SpyDate]=#" & Format(Me.saleDate, "yyyy-mm-dd") & "#", dbOpenDynaset)
  2. K

    Sql for date problem

    [SOLVED] Sql for date problem I have the following sql statement to update some records to a table by a form: Set rs = cdb2.OpenRecordset("SELECT * FROM tblSpy WHERE ID=" & Me.cbxItems.Value & " And [SpyDate]=#" & Me.saleDate & "#", dbOpenDynaset) I believe that he problem is on Date syntax...
  3. K

    POS simple DB

    Hi all, I am trying to create a simple POS (Point of Sale) db. For this purpose I created 3 Tables (TblSales, TblProducts and TblReceive). The tables are linked (one to many) by product ID key. For sales I have a main form which contains 2 filtered combos so I can change the product from...
  4. K

    Delete multiple Records from Table by listbox

    Re: Dlete multiple Records from Table by listbox Yes it works! Thank you very much Paul. You saved my day and my night ! Thanks again !
  5. K

    Delete multiple Records from Table by listbox

    Re: Dlete multiple Records from Table by listbox 2 of my efforts without success: DoCmd.RunSQL "Delete from Tbl2 Where ID1= " & Me.List0.ItemData(vItem) And DatePar="#" & Me.ParDate & "#" And DoCmd.RunSQL "Delete from Tbl2 Where ID1= " & Me.List0.ItemData(vItem) And DatePar= " &...
  6. K

    Delete multiple Records from Table by listbox

    Re: Dlete multiple Records from Table by listbox Unfortunately I can not find a solution. I tried delimiters also but nothing. Any other help ?
  7. K

    Delete multiple Records from Table by listbox

    Re: Dlete multiple Records from Table by listbox Thanks Paul for your reply. I will look the site that you suggest and I will try...
  8. K

    Delete multiple Records from Table by listbox

    Hi all, I have the following code for adding multiple records in a table (Tbl1), selecting by a form listbox (list0) and works fine:Private Sub BtnAddRec_Click() Dim rst As DAO.Recordset Dim VItm As Variant For Each VItm In Me!List0.ItemsSelected Set rst = CurrentDb.OpenRecordset("Tbl1"...
  9. K

    add record to table from a form using unbound list and text boxes

    Ok, with the following simple code I solved the problem;): Private Sub AddBtn_Click() Set db = CurrentDb Set rs = db.OpenRecordset("Table1") rs.AddNew rs("Category") = Me![entypolst] rs("Product") = Me![entypotxt] rs.Update rs.Close Me.[SFTable1].Requery End Sub Thank you all for interest
  10. K

    add record to table from a form using unbound list and text boxes

    I am searching a way to import new records to a table by a form which contains a combobox and a textbox. If there is another way please help me! Thank you in advance
  11. K

    add record to table from a form using unbound list and text boxes

    Thanks for your reply I try your suggestions but the problem is still the same. Nothing happens on table.
  12. K

    add record to table from a form using unbound list and text boxes

    Thanks for your interest you' re right, I forgot these τεστ lines of code by mistake. I quote the correct code but the problem remains:Private Sub AddBtn_Click() Dim strSQL As String Dim db As DAO.Database Dim rs As DAO.Recordset Dim ctl As Control Dim varItem As Variant On Error GoTo...
  13. K

    add record to table from a form using unbound list and text boxes

    Hi all, I have a form with 1 unbound listbox as drop down list (entypolst), an unbound text box(entypotxt) and a command button. The list box reads items from a table. I want to change a value (text) on listbox, input a text on textbox so pressing the button add a new record in a table (Table1...
  14. K

    Count Date from Text format field

    I thing that I founded a solution. I changed the formula as: Exp1: DCount("[CountryofOrigin]","MainTbl","[CountryofOrigin]='ITALY' And IIF(IsDate([Finalized]),DateValue(Nz([Finalized],#31/12/9999#)) < DATE(), 0)") and works fine. Anytime thanks for your help.
  15. K

    Count Date from Text format field

    Thanks for your interest, unfortunately I take a syntax error. I tried to change the formula as : Exp1: DCount("[CountryofOrigin]","MainTbl","[CountryofOrigin]='ITALY' And IsNumeric([Finalized]) And IIF(IsDate([Finalized]),DateValue(Nz([Finalized],#12/31/9999#)) < DATE(), 0)") and runs but I...
  16. K

    Count Date from Text format field

    The field "Finalized" is a text format field that takes 3 type of values: Dates as dd/mm/yyyy format, a value of normal text (the words "pending" or "not pending) or still blank. I try to find a way counting the dates < current date in a query , counting blanks and text in another query.
  17. K

    Count Date from Text format field

    Thank you for your reply, I tried your solution and works fine for dates count if some of the fields is blank. If contains other text is not working. Thanks again
  18. K

    Count Date from Text format field

    Hi All, I have a text format field with name “Finalized” that takes values as date format (dd/mm/yyyy) or other simple text or remains blank. I try to make a query (from query builder) counting the records with date> current date. For this I use the formula: Exp1...
Back
Top Bottom