Search results

  1. R

    How to deter the <Cancel> from MS Folder Dialog box

    Function dialogFolderBrowse() As String Dim fp As FileDialog Dim vrtSelectedItem As Variant Dim VarX As String 'this next line is an optional warning to the user so they know what is about to happen 'MsgBox "LOCATE THE DESIRED FOLDER!!", vbOKOnly 'Create a FileDialog object as a Folder...
  2. R

    Query last 10 unique records

    I got a large transaction file with deplicated records!! For unit price checking, I need to copy the last 10 unique records to another file with the same criteria but price is not the same as the current checking record. For instance, I got 5000 records with around 400 records unit price is...
  3. R

    Combo box defaultvalue

    I got a COMBO BOX with 2 columns , for instance code and name. CODE NAME 123 JOHN 124 JACK 125 BILLY 126 MARY In the OPEN form action which the form using this combo to do some query action, I want to put a default value to this combo box after a VBA query result of...
  4. R

    how to do some action after EXIT a Command button

    Sorry!! I am not sure I got your meaning! Anyway, I have changed the statement to as follows but when I put statement such as MSGBOX "AFTER OPEN FORM" to test, the message appeared in the open form but not appeared after user closing the form!! Please help!! Thanks a lot!! DoCmd.OpenForm...
  5. R

    how to do some action after EXIT a Command button

    Private Sub Command124_Click() On Error GoTo Err_Command124_Click Dim stDocName As String Dim stLinkCriteria As String stDocName = "PRINTSQUARE 1" DoCmd.OpenForm stDocName, 3, , , , 4 Exit_Command124_Click: Exit Sub Err_Command124_Click: MsgBox Err.Description...
  6. R

    Select specific dated recordset

    Set TRANS1 = db.OpenRecordset("SELECT * FROM MASTER WHERE DatePart("yyyy", TRANS1![CDATE]) = " & 2014, dbOpenDynaset) In the above recordset selection, the ACCESS seems do not allow to have the DATEPART("YYYY") function in the syntax. As CDATE is a table field with date/time data type. Just...
  7. R

    How to know emplty recordset

    I have the following VBA code to select certain records from table to recordset, however, sometimes no records existed and movefirst should give error message. Just want to know how to know there got no records in the TRANS2 in case no criteria is matched?? Thanks Set TRANS2 =...
  8. R

    Dlookup (criteria conflict)

    I have changed just some variable names, but it couldn't locate the record for me even though it existed in the table. Any idea?? Am I missing something?? Thanks a lot!!
  9. R

    UPDATE query won't work after warning set to false

    Yes, there is a spelling mistake over there. And it simply couldn't set warning back to normal. I found out the problem is not due to that. It seems when I run the update query using hard code e.g. "T12345", it works well. But when I use something like the following: Forms![workingsum].Text168...
  10. R

    UPDATE query won't work after warning set to false

    DoCmd.SetWarnings False Dim stDocName As String stDocName = "Tupdate1" DoCmd.OpenQuery stDocName, acNormal, acEdit DoCmd.SetWarnings Ture If included the two setwarning statements, the update query won't work but when running without them, the update query worked well. Any idea?? Thanks!!
  11. R

    How to query YES/No field??

    Ok! My problem is that instead of just showing either True or False, I also want to have an option to show all True and False in the same query. Can I have this kind of query!! Thanks!!
  12. R

    COMPARE DATE variable to DATE/TIME FIELD

    For example, I have a variable TEXT233= date (i.e.today "2014-2-19') and want to compare to a table filed, for instance invoicedate, which is yesterday with value I believe something liked "2014-2-18 10:20:30 am". I believe it cannot be directed to do the following statement and make it compare...
  13. R

    How to query YES/No field??

    Field in table with data type as yes/no. If I create a query with condition to show either 'yes' or 'no' for this field. For the time being, I have to put either "='yes' or '=no' in the condition to accomplish my query. According to my knowledge, I could create a list box filed instead of...
  14. R

    COMPARE DATE variable to DATE/TIME FIELD

    In VBA, how to compare date variable with date/time field from table, as when defined the data type in table, date/time option is the only choice for date data type even though I don't want the time portion. MANY Thanks!!
  15. R

    field filter or field list

    Table master : CustNo. CustName, transaction no Table transaction : Transaction no, product type, product color, product range, qty, price and subtotal Table product range: Product type, Product color and product range I create a form and subform...
  16. R

    Combo box default

    I got a combo box with a few columns for locating query activity. However, how can I make use of it to locate a particular record according to predfined values, for instance in a loop, to locate records. The combo box got 3 columns, just want to know the syntax to define the combo box according...
  17. R

    HOW to create a Hexdecimal file using VBA

    Sinking!!?? :confused: I have tried to understand the function coding, but at least I don't know where and how to put the TIF filename?? Thanks!!:(
  18. R

    HOW to create a Hexdecimal file using VBA

    Sorry! I have tried to understand the function coding, but at least I don't know where and how to put the TIF filename?? Thanks!!
  19. R

    How to close the second Subform

    How to close the second subform?? IT seems the'DoCmd.Close acForm, "subformname 2" is now working!! Thanks a lot!!
  20. R

    Selection box in Subform and assigment in Subform

    Are Access cannot work in these ways?? I just want the second field filtered results based on first field and the thrid field equal to one of its list value based on first field result. Second field is a selection box fields and third field is a list box field . Please help!! Thanks!!
Back
Top Bottom