Search results

  1. E

    Having problem putting a Form _BeforeUpdate event

    Hi, I have On Load, Current, After Update events on a form, which all work fine. But, when I add a Before Update, I get the error: "Procedure declaration does not match description of event or procedure having the same name". Can anyone please help me to resolve this issue. Following is my code...
  2. E

    Modify an Existing Record in a DAO Recordset

    Sorry, I had dbs.Execute Query2, instead of db.Execute Query2. Now it works. I really appreciate your help pbaldy.
  3. E

    Modify an Existing Record in a DAO Recordset

    I changed the code, but I get this error: "Object variable or With block variable not set" If Not rstTest.EOF Then MsgBox "Order: " & rstTest!Order_ID & " has " & rstTest![The Remaining Units] & " units left" If rstTest![The Remaining Units] = 0 Then...
  4. E

    Modify an Existing Record in a DAO Recordset

    I added an update query to my code, but that does not update the order status. Can you please help me to correct the code. Private Sub Form_AfterUpdate() Dim dbs As DAO.Database Dim rstTest As DAO.Recordset Dim strQuery As String strQuery = "SELECT...
  5. E

    Modify an Existing Record in a DAO Recordset

    I tried that already. But when the condition meets, for example, when I move the mouse cursor on the previous records(on the spreadsheet view of the form) which I want to Add/Edit, it gives the error :" you cannot go to a specified record". So, Is there any way that I can edit/add to the...
  6. E

    Modify an Existing Record in a DAO Recordset

    Ok Thanks.I will create an update query. I also have another question, do you know how I can limit data entry on my form (split design) when If rstTest![The Remaining Units] = 0 Then .
  7. E

    Modify an Existing Record in a DAO Recordset

    Alright, thanks for let me know the reason why is not updating. But, do you know how I can change a field related to one of the items I am getting from the query.
  8. E

    Modify an Existing Record in a DAO Recordset

    Hi, I have written the following code. I want to change the status of my order when reminaing products shipped is equal to zero. When I run this code I get error " Cannot update. Database or object is read only". I think that this error is because that I am using the front end of the database...
  9. E

    too few parameters. expected 1

    Thanks a lot. It worked.
  10. E

    Selection from combo box

    Thanks, I used concatenate method, which I did not know before.
  11. E

    too few parameters. expected 1

    Hi, I have a button on my order form. I have written the following code on on-click event of the button to read one of values from the order form and return some values using query. In my code I put a msg box to test the query.Anyways, my problem is that I get an error "too few parameters...
  12. E

    Selection from combo box

    I have an unbound combo box with three columns, which get the values from a query. The first column is hidden. When I close the combo box after my selection, only the second column value is shown on the box. Is there any way that both the second and third column being shown on the box after...
  13. E

    Limit the data addition

    I just want to restrict the user from adding new records as soon as the number of records reach to a specific limit. Following is my code: Private Sub Form_AfterUpdate() Dim dbs As DAO.Database Dim rstTest As DAO.Recordset Dim strQuery As String...
  14. E

    Limit the data addition

    I have a split design form, where user can select on any row and column of the spreadsheet view of the form and edit the data. Now, I want to write a code to limit the data addition(Row addition) to a certain number. But I still want to be able to edit the previous records added to the form. I...
  15. E

    error 94: invalid use of Null

    Thanks, you are right. I made it work by just removing MsgBox CollectionTime, because I had null value for CollectionTime, therefore the MsgBox was causing this error.
  16. E

    error 94: invalid use of Null

    Hi, Can anyone please let me knowhow to resolve error 94 in the following code: Private Sub Form_Current() Dim strTime As String Dim strHour As String Dim strMinute As String If (CollectionTime.Value) = "" Then MsgBox CollectionTime Me.Hour = "" Me.Minute = "" Else strTime =...
  17. E

    Having two combo boxes bounded to a field of a table

    Yeah, I think it does not worth it. I needed two combo boxes to be used as hour and minute. I want to have 0 to 23 in hour box, and 0 to 59 in the minute box. But now, I think I should either use two diffrent boxes or use an input mask.
  18. E

    Having two combo boxes bounded to a field of a table

    Thanks, but the combo boxes still stay unchanged. Just to let you know, my form is a split design form and when I click on any row of the spreadsheet view of the form, I can see them in filed boxes at the bottom except the combo boxes, which their values stays blank or the same as what I...
  19. E

    Having two combo boxes bounded to a field of a table

    I greatly appreciate your help gbnz. I implemented your code and it woks perfectly. However, is there any way that when I go to a specific record, the values of the combo box gets updated to what they should be. Because right now, when I go to a new record, the values of the combo boxes stay...
  20. E

    Having two combo boxes bounded to a field of a table

    I have two combo boxes containing integers on a form. How can I store the values of these combo boxes in a field of a table separating them by comma or semi colon?
Back
Top Bottom