I am working on a Reset Password form for a database. The table is called tblUsers and has three fields (ID, Login and Password). The form has a text box where the user can enter in a new password, I already have the code that checks the current password and everything I just can't figure out how to update the password in the table. The textbox is named txtNewPass.
I am setting up a db for a ecomm site and the vendor prices are in 4 different currencies. I currently have the price fields data type as a "number" (long integer). Can the data type "currency" handle different currencies all in one table? Do I need to set up a seperate price table for all the products in each currency? Any help is appreciated.
I preface this question as most newbies do. I have just started using Access(2000) and have built rebuilt/converted from DOS a database for a basketball club. I did start from scratch and just inported the table data.
I have already made a number of forms and subforms, e.g. searching for a player displays all the other players in that team and displays the team staff from the relevant tables. So I understands the concepts.
What I have tried to do, and succeeded in part is to populate some of the fields of the Player Account records from the Fees table. I managed to do a query from the Fees table for this using a drop down for the FeeCode, which fills in the Fee Description and Fee Amount. However if I change the Fee Amount it changes all of the fee amounts for that Fee Code type. (I think I solved this myself as it is a query and that is what it should do, correct me if I am wrong). Note that all of the retrieved data is static except for the Fee Payment, which can be different amounts, this is where it changes the source. Also as it is a query I think , the retrieved data just shows on the screen and doesn't get written to the Accounts table (not the description though).
So I have obviously gone about this the wrong way and rebuilt the Accounts trying to use lookups. Here is my problem (finally you say). I cannot get the default value to lookup the fee table based on the fee code. Note I have not started on the VB side yet so please be easy on me. There is a drop down box for Fees Charged but this lists nothing, so like the query before nothing gets written to the Accounts table.
I think (maybe I don't) understand the lookup thing as I used an old (DOS) database before and did the same thing and was able to change the default value just for that account. i.e. lookup the table>field where the fee code is = to this. I have tried the subform wizard a few times but just cant get it right.
Should the lookup be in the table field or the subform. Am I on the right track and if so how do I get the retrieved info from the Fees table into the Accounts table. My end result should be something like this.
Fee Code(lookupFees - write to accounts), Description (lookupFees - display only), Fee Charged(lookupFees - write to accounts), Fees Paid(lookupfees - modify write to Accounts), Date(Accounts), Receipt Number(Accounts).
Thanks for taking the time to read this, I have tried to give as much information and hope I haven't given too much.
Can anyone help - I am importing an Ascii text file with decimal numbers ie (144392.26). the receiving field is defined as double with decimals set to auto. I have tried many other formats such as fixed 2 decimals, or Currency 2 decimals. In all cases the data has changed from its original value to 144392.265625 which of course rounds to 144392.27 on all reports. If I use a link to the same Ascii file the data retains its original value when it is appended to an empty table. But ... When I try to use that correct value in the appended table to update another table it again converts the amount to multiple decimals and may increase by more than .01.
Hi, This query will allow me to view payments that are made between 2 dates. I would like to know how to flip the query around so that it gives me the payments that have not been made. I think this would be described as returning the null values?
The SQL code i have at the momnet is: SELECT download20060602.Date, download20060602.Description, download20060602.Amount, Members.FirstName, Members.[Mid Name], Members.Surname, Members.[Memb No] FROM Members LEFT JOIN download20060602 ON Members.description = download20060602.Description WHERE (((download20060602.Date) Between [Enter Start Date] And [Enter End Date]));
I have a simple add form that will add an entry to one of two tables: Box 1-1, or Box 1-2.
They have the exact same fields. In the add form, I want the user to specify a Rack field and a Box field. Box 1-1 would be Rack 1, Box 1. Box 1-2 would be Rack 1, Box 2 (there will be more tables later, but just using two for now until I get it working).
But right now my form always adds to the table Box 1-1 - I can't get it to switch.
I've added the code I have so far below. The first part is what I'm having trouble with, the second part just uses a Submit button to add a new record - I'm just including it in case it's interfering in some way I'm not seeing. I'm running Access 2007.
Code: Private Sub Switch_BeforeUpdate() If Me.Rack.Value = "1" And Me.Box.Value = "1" Then Form_Add.RecordSource = "Box 1-1" ElseIf Me.Rack.Value = "1" And Me.Box.Value = "2" Then Form_Add.RecordSource = "Box 1-2"
Currently I have a calculated field in my table; however, under certain circumstances I need to change the value to another value which is not related to the calculation. I understand that the calculated fields are read only (why is that?), so I was wondering if there was any way to change values within a calculated column without actually changing the expression itself.
I need any code or way that whenever any field of a record according to unique ID changed the code must save the changed field name and the current date in a specific field in another table (first field store the ID and the second one detail about changes) with add record mechanism. Suppose I have a table about the information of students with the name std_info and another info_report and when any changes make to the any field of std_info the field number and the unique ID to the table info_report. I want to use this system to record which user make changes to which records.
I'm not sure if this is a Table question or a Form question...
After a user enters data into all the fields on my form (ticket #, date, time, etc) and submits that form, I want to prevent them from going back to that record (or any record, for that matter) and make a change to it. Currently, they can do a "Find" on a specific ticket # while in the form and make any kind of change they wanted. ie: change the time they reported to a work site...
Is there an easy way to prevent this from happening?
I have Form F_CashSalesHead with a subform F_CashSalesInvFoot with one-2-many relationship on their tables. Subform contains a checkbox field that I use to lock the record set (On a command button click it runs one update query to add value 1 to each checkbox to make Enable=False all the records of current invoice on the form).
One-2-many relation ship is made on InvNum field in both tables.
When I open F_CashSalesHead form, bcz of some code line I wrote on On Load event of F_CashSalesHead , at the beginning it give massage how many invoices are pending to lock and would you like to see. If click “Yes” to see list, it opens a small form that called F_Count_Unlocked_Invoices showing invoice numbers and unmarked checkbox which is pending to lock. This small form is based on following query,
SELECT DISTINCTROW T_CashSalesInvFoot.InvNum, T_CashSalesInvFoot.CashSalesCustomerName, Sum(T_CashSalesInvFoot.Lock_Cash_Inv) AS [Sum Of Lock_Cash_Inv] FROM T_CashSalesInvFoot GROUP BY T_CashSalesInvFoot.InvNum, T_CashSalesInvFoot.CashSalesCustomerName HAVING (((Sum(T_CashSalesInvFoot.Lock_Cash_Inv))=0));
This works fine.
What I am looking for is, I want to use the same F_Count_Unlocked_Invoices form for Credit Sales invoice also with the same trick. Because I don’t want to create another same form and write code that help to increase size of db.
Can it be done just by changing record source of form F_Count_Unlocked_Invoices? Or what is the way to do it?
Hello, I have a form with a subform. I want to change the record source on the subform during an OnClick event. I am not sure what I'm doing wrong, but I get a "object does not support this method" error. Can anyone help? Thanks in advance.
Hi guys, I need a little help on next record stuff...:eek:
Can someone please explain how I can make my database actually go to the "Next" record after I update the "LName" field on my form? My database is sorted on "LName". After I update the "LName" field and save the record, the sort order is messed up. If I requery the form in the sub routine, the database goes to the first record. I need it to go to the "Next" record (the one that would have actually come next before I changed the LName). For example, if my database contains these names:
Baker Doe Franklin Goodwin Johnson Jones Smith Taylor
and I change the current record's LName from Franklin to Phranklin, I expect the database to go to Goodwin (the record that would have followed Franklin) after pressing my next record command button. Likewise, if I changed Phranklin to Franklin, I expect the database to go to Smith (the record that would have followed Phranklin) after pressing my next record command button.
I've tried different versions of FINDFIRST on this site, but can't get it to work. I would like to find the next record based on my key field (autonumber) named "rec_id".
hi all, I have three values in a record labelled "Local, National & Rural", I want the user to be able to select one of these options, (e.g. Local) and then be able to right click and sort be selection.
However, when I lock the combo box, you can't select anything but if it is unlocked, it changes the current record to whatever the combo box has selected.
I'm this is a simple issue. I have a combo box which can have the following status's: Not Started, In Progress, Complete. Depending on the value of the combo box i want a different image to show. So if not started is selected i want the user to see a red box. If Complete is chosen, a green box will show. i can do this easily enough but my problem comes in when i go to the next record. The boxes just stay visible regardless of what option is displayed. What event is triggered when you go to the next form?? Form Open / Load doesnt seem to work. :mad: :confused:
I have a text field "Record Last Updated" on a form formatted for date/time that I would like to update after a record is changed or added. So for every change or addition the field would update to the current date. The code I am currently trying to use is as follows:
'Assign current system date to Last Updated field if change of data occurs in any field For Each ctl In Me.Form.Controls
If (ctl.ControlType = acTextBox) Or (ctl.ControlType = acComboBox) _ Or (ctl.ControlType = acListBox) Then If Nz(ctl, "") = ctl.OldValue Then
Else txtLastUpdated.Value = Date End If End If Next ctl
This executes in the forms After_Update event procedure. Problem is I get an error 3020 "Update or CancelUpdate without AddNew or Edit" when moving to the next record ? I have tried using .Edit and .Update but those come up as an invalid reference? Any suggestions would be appreciated. Thanks in advance
I have a form that is linked to a table. tblContacts
On the form I have added a listbox which has every possible Contact (Name) listed. I wanted to be able to click on a contact name and then have the form bring up all the information related to the contact.
right now i have on the click of the listbox a msgbox that gives me the contact id associated with the contact name.
BTW, this is a project i am taking over from someone. If it was my choice I would be creating a web app.
I have a small issue, but cannot solve it. I have a form with a textbox bound to a time(7) on a SQL server linked table.
Even if I put the format as "Short time 24h" or "hh:mm" it will always come out with seconds, nanoseconds, etc as soon as you change record. I would like to avoid using the "current" event to keep the "hh:mm" at any record change.
I am rebuilding a file that deals with a lot of active and inactive accounts. I would like to change the inactive record to a yellow or red when a check box is marked. It has been about 15 years since I have written any macros or VB functions.
I want to change misspelled records, but the misspells are in the primary key of my table. By changing the values of primary key fields, can I break table relationships? I'm not changing field names, just field values of a primary key field.
How to fill values in a new record with data from previous record?
I've total 11 columns in a table and values in 3 4 columns are repeating for few rows before it needs to be changed eventually. I want to fill these rows with values from previous record.
THEN . . . . I need to also isolate certain periods, for example July- March for YTD (year-to-date) analysis and compare YTD of 2006 with that of 2005.
I'm new here, mostly learning to do stuff by trial and error. I have a sneaking suspicion that I could easily search out the answer to my question if I had the right vocabulary, but I don't think I do...
Anyway, my question, hopefully you can help me with.
I've got a tabular form that has a couple of comboboxes, and then a text label:
ComboA....ComboB....Label
What I'd like to do is change the label for each row based on the Combobox data...
That's what I want. How I'm currently doing this is having a Sub called whenever the Combo boxes are changed, to change Me.Label.Value to 3, in this example. Of course, what instead happens is I get...
Which is not what I want at all. Is there a way to change the value of the label in(for instance) the second row, without changing /all/ the labels in the continous form? I'd be really handy to know how to do that, but I just can't puzzle out a way.
If that's not possible... Any other way to get my labels to display the information? Part of the problem is that my function relies on information stored in variables in my form, and I'm not sure I can access those just from the source propery of the label... What I need, essentially, is to put in Label's value the result of MyFunc(ComboA.Value,ComboB.Value,formvariable1,for mvariable2).
i have a database with a large number of records. Navigating through the records through a form one by one is a pain, so i want to create a text box where you can enter the ID number of the record, and whichever record has the matching ID number it changes to that specific record. I know that something like this is already apparent at the bottom of Access, but i want my user to do everything within the database itself, as all of the panes are removed whilst being used