Search results

  1. T

    Report printing blank pages...

    Hi.. a suggestion..: Page Setup / Columns Tab / Same As Detail checkbox click..
  2. T

    Syntax for dates in vb

    I think this way work.. varWhere = varWhere & "[NewWOno] " & "Like '" & Me.txtWOno & "'" & " or [oldWOno] " & " Like '" & Me.txtWOno & "'" & " And " I hope you think of the right.. ;)
  3. T

    how i can run this code with all records

    Set rs = CurrentDb.OpenRecordset("....") this section, you must specify the form's source table or query.. Set rs = CurrentDb.OpenRecordset("table_name") as...
  4. T

    Syntax for dates in vb

    inattention.. :cool: Thanks for the correction.. ;)
  5. T

    Syntax for dates in vb

    Hello.. Try this way.. dim sdate,edate as integer sdate = clng(cdate(Me.txtStartDate)) edate = clng(cdate(Me.txtEndDate)) varWhere = varWhere & "[NewWOdate] Between " & sdate & " and " & edate
  6. T

    Macro to save form in PDF

    Hi.. Try this..: DoCmd.OutputTo acOutputForm, "form_name", acFormatPDF, _ me.textbox_name & ".pdf", True, "", 0 .
  7. T

    Find target button

    Hi.. you can use it.. Be sure to include the necessary reference..: VBa editor / Tools / References / Microsoft Office xx.x Object Library Dim dlg As FileDialog Dim si As Variant Dim FileName As String Dim vrtSelectedItem As Variant Set trz = Application.FileDialog(msoFileDialogFilePicker)...
  8. T

    datediff function on access form. 2003. Returning "#ERROR"

    function is implemented correctly. need to search for error in different places.. Try it. what the result will be? =([start date]-[cbc_test_done])*24 .
  9. T

    Update SQL with variable

    Hi.. can use this way with vba..: currentdb.execute "INSERT INTO Table1 ([Field1],[Field2],[Field3]) SELECT '" & var1 & "'" & " ,[Field2],[Field3] FROM " & _ "Table2 WHERE [Field4] = n "
  10. T

    Filter a continuous form

    Hi.. with between operator, equal operator should not be used.. also, Try giving the full path of the text boxes ..: Me.Filter = "[ScheduledStartDate] Between [Forms]![form_name]![txtStartDate] And [Forms]![form_name]![txtEndDate]" Me.FilterOn = True it's another way..: docmd.applyfilter...
  11. T

    Cf

    IIf([Lock]=-1,"Pass","Fail") Hi.. Use -1 (or true) for the correct value .. 0 (or false) for the opposite..
  12. T

    Convert Form to PDF problems

    Hi.. There are a few ways to do this. I suggest one of the..: On Error GoTo hata Dim trz, oldsource As String trz = " [ID]=" & [ID] 'Change with the name of the ID field oldsource = Form.RecordSource trz = "select * from(" & oldsource & ") where " & trz Form.RecordSource = trz...
  13. T

    Returning this months and next months records

    Hi.. only to records this month, can use this criterion..: between dateserial(year(date()),month(date()),0)+1 and dateserial(year(date()),month(date())+1,0) records only for the next month, can use this criterion..: between dateserial(year(date()),month(date())+1,0)+1 and...
  14. T

    newbie needs help, what is this called

    Re: newbie needs help, what is thsi called Hi.. Cross query might be useful maybe..: transform min(data) as dt select PatientID from table_name group by PatientID pivot VisitType
  15. T

    Printing Reports From a Form

    Hi.. Use this command.. form.refresh If IsNull(Me![CARNUM]) Then MsgBo.... .................
  16. T

    Selecting lowest value from multiple fields

    I'm glad you like it. I forgot the server.. ;) If you want, the same result, for the server, not using the function, the query can do it with..: select OriginalData.ProfileID, Name, Profile1, Profile2, Profile3, Profile4, MINP from OriginalData left join ( select ProfileID...
  17. T

    Selecting lowest value from multiple fields

    Hello .. I thought you wanted the smallest value in the entire table of values​​. I guess, do you want for each record separately. I prepared a function. You can see the results of the query named query1. Greatest value and the lowest value of both Sorry, my English is not very good .. :(
  18. T

    Selecting lowest value from multiple fields

    Hello again .. :) this query take the smallest value other than 0 ...: select ProfileID, Name, tt from ( Select ProfileID, Name, Profile1 as tt from TblSample union Select ProfileID, Name, Profile2 from TblSample union Select ProfileID, Name, Profile3 from TblSample union Select...
  19. T

    Selecting lowest value from multiple fields

    Hello.. ;) This query lists all the profile fields in the most lowest value ones..: select ProfileID, Name, tt from ( Select ProfileID, Name, Profile1 as tt from TblSample union Select ProfileID, Name, Profile2 from TblSample union Select ProfileID, Name, Profile3 from TblSample...
  20. T

    Question How do I export selected queries to separate excel files

    Hi.. ;) With this procedure, using the values ​​in the table, with one command, you can export queries..: Dim rs As ADODB.Recordset Set rs = New ADODB.Recordset trz = "select * from tablename" rs.Open trz, CurrentProject.AccessConnection Do Until rs.EOF DoCmd.OutputTo acOutputQuery...
Back
Top Bottom