Search results

  1. W

    Using a String to reference a Textbox

    Oh I understand not sure if this would be good for my case, the form is based on a table called group (a group of assets), I'm using a query to filter which assets are displayed/can be edited from in the group and the filter is determined by field 'Group Type' (there are three different group...
  2. W

    Using a String to reference a Textbox

    Sorry can you elaborate on that don't really understand....
  3. W

    Using a String to reference a Textbox

    I have a recordset and am looping through the records taking field values and would like to display each one in a separate text box in a form, each textbox has a similar name - Textbox1, TextBox2, TextBox3 etc Is there a way of using a string to reference a textbox so i can just change the last...
  4. W

    VBA query parameters not working

    Yes, it works thanks so much. So just for reference if was number data type would it be just like I had it before? Thanks again
  5. W

    VBA query parameters not working

    Asset Number and Group Type are both text data types. And I have added in line of code thanks still getting used to using recordsets. And know its bad practice to have spaces.... thanks for help
  6. W

    VBA query parameters not working

    Been scouring the internet for ages to understand why this isn't working whenever I run it I get this error message 'Syntax error (missing operator in query expression '((([Asset Group].[Asset Number]) = AN00001) AND ((Group.[Group Type]) = Camera Unit))'. I've copied this code straight out from...
  7. W

    Cancel New Record

    Oh Sorry so you did, I'll try that. I have undo command in there too as also use it for when a user changes a record and doesn't want to save changes, so redoes it to original before saving. Will this work for this case too? as have this code on all my forms. Thanks I appreciate it
  8. W

    Cancel New Record

    Option Compare Database Public CancelPressed As Boolean Private Sub Cancel_Click() Cancel = True Forms![Project Budget].Undo DoCmd.Close acForm, "Project Budget" End Sub Private Sub Form_BeforeUpdate(Cancel As Integer) If CancelPressed = True Then Cancel = True End If End Sub thanks for looking
  9. W

    Cancel New Record

    Thanks I just tried that, but still didn't work. It's actually saving to table before cancel button has been clicked... or is will this remove it? any other suggestions
  10. W

    Cancel New Record

    I have a button that opens a form and goes to a new record and vba automatically fills in a textbox and a combo box. I have a canel button that contains Form![FormName].undo DoCmd.Close acForm, "FormName" it deletes everything the user puts in himself but keeps the record with the fields vba...
  11. W

    report with a field not in any table possible

    I was wondering the easiest way to create an unrelated field that the user can just input data on opening of report and it will be displayed on the report. I want to be able to open a report and a user is prompt to enter a string or choose an option (it is current status where it can only be...
  12. W

    Table Relationships

    A project can contain many budgets and many periods. A budget contains a budget for a period, and there are several periods that can have that budget. for example I have a project that has a budget of £20 a month, and lasts for three months. And a period contains the actual cost for a month. So...
  13. W

    Table Relationships

    Thanks for the reply, I altered want you said. However, it still didn't prevent what I wanted, for example adding a period with project 1 and budget 1 was allowed even though only record in budget that had project 1 is budget 2...
  14. W

    Table Relationships

    I have the three tables related like shown in attachment. I want it to not let a period be created with a projectID and BudgetID that doesn't match any record in the Budget table. I thought the relationship would prevent this, any help appreciated, Thanks
  15. W

    Missing part of the look ups

    Ok I tried that and the tables shows up the full ID now including the letters in every table, but it still doesn't show up correctly in the forms some look ups show it correctly in the top box but the drop down options are just the numbers but when you select a number it displays it correctly at...
  16. W

    Missing part of the look ups

    OK I will try that, should I not have input masks and specified field sizes at the table level too then? thanks for your help
  17. W

    Missing part of the look ups

    I've created several tables each that are linked and use look ups, the lookups are a couple letters followed by a number e.g. HP00001 and they display correctly in the table they originate from but when in other tables it only shows the number part so just 00001, I don't understand why, any help...
Back
Top Bottom