How Do I Handle " In Text Fields
Aug 16, 2006
How do I handle " in text fields - I have a few customers names like "Zoom" - who insist the name is with " in it.
This buggers up queries and filters etc - becuase of the confusion the " creates.
How do i solve this?
View Replies
ADVERTISEMENT
Jan 8, 2007
Hi friends,
I am new to this forum, and I am facing a problem while learning MS-Access.
I am preparing a database that stores the marks obtained by students in a particular paper in addition to their particulars in tables.
A query is then generated to canculate the aggregate marks and result (Pass/Fail) for the student. It is then presented in a report fomatted as a marksheet, as well as one tabulation chart.
The database is very crude in format, but I am happy with it since I do not know programming at all, and still I could make it.
I have used in built menu of "ms-access" and mouse clicks only for generating query. It was a learn by doing method.
The problem is that my marksheets require absent students to be marked as "ABSENT" or something of that kind. If I convert my Null values to :
Expr2: IIf(IsNull([E_1]),"ABSENT",[E_1])
It shows ABSENT for null value, but refuses to make column total for E_1; On the other hand if I do not enter such expression, it makes column total in tabulation report, but fails to mark "ABSENT" to those who did not appear. So I have to lose one thing to gain another, while I need both.
Can anybody help me at this?
pc
View 5 Replies
View Related
Jan 29, 2005
I have an input form that has many fields, how do I go about fragmenting the data collection.
I thought I might group related data fileds together ie personal details, contact details and have a separate form for each data grouping or one form and make the fields invisible after they are filled in and then make the new data group fileds visible ie overlaying them so it appears to be a new form. I am not sure and would appreciate guidance.
regards
Peter
View 3 Replies
View Related
Nov 21, 2013
how can i disable a textfield or two in a form when the textbox is unchecked also how do i add a default value for it while the textbox itself is disabled, can i get away with it by adding a default value on the textbox?
View 14 Replies
View Related
Jul 11, 2005
Hi, here's the scenario...
I'm building an ASP based email application which is to send emails to different user groups. The email addresses in the database need to be able to be assigned to more than one user-group, and an administrator needs to be able to add user-groups to the database.
So effectively, there may be hundreds of user groups and hundreds of users.
What is the best way to store this info in an Access database? Do I let the administrator create a new table column in the userEmails table whenever there is a new user-group added, or do I store a series of userGroupIds in a text field along with each email address and delimit them so that I can split them into an array?
I'm really not sure how to go about this, so any help would be much appreciated.
Thanks...
View 2 Replies
View Related
Jul 10, 2006
Hello,
What is the best way to handle notes on a form?
The DB is for recording Quotes and Orders taken over the phone.
Is it best to have a seperate table w/ a NotesType field so that all notes are stored in a central location? Or is it better to store notes for each quote/order in the Orders / Quotes table itself?
Also, if data is entered into these fields using subforms, is it possible to have the notes displayed outside of the subform in a box format, to allow plenty of typing room?
If anyone has a good example of a smart notes system implementaion, it would be very appreciated.
Thanks!
View 3 Replies
View Related
May 25, 2005
I have Four tables, CustomerTBL(holds all the customers for both companies); NoteTbl; AgeingTBL1 (this is for one company) ;AgeingTBL2 (this is for a child company)
I need to keep the 2 ageings seperate.
I want to creat a form from the customer table (so you can make edits to contact info and such)
Then I would like a subform with the ageingtbl1 and the note table to be linked together, but I only want the records from the customer table and note table to come back that match the ageing for that perticular customer.
I think I made this more confussing then it needs to be
View 2 Replies
View Related
Aug 13, 2007
I have a parent form (called PR_CR_Form) that has a subform called SubFrm_DefectClassification. I am trying to log all changes to the Access database. I am using the VBA code from the Microsoft website for article 197592. It works great. However, it only allows me to capture the changes to the main form. The VBA code has the following statement:
Set MyForm = Screen.ActiveForm
This makes MyForm point to the parent form (PR_CR_Form). What I would like to do is to make MyForm point to the subform (SubFrm_DefectClassification). However, I can't seem to do this. I tried the following:
Set MyForm = Forms!PR_CR_Form!SubFrm_DefectClassification
but this didn't work.
I would very much appreciate it if someone could please tell me how to do this.
Thank you!
-Al Oberneder
View 2 Replies
View Related
Dec 3, 2006
Hi guys,
I've noticed a few posts on the subject of images but there's lots of different scenarios and I'm hoping someone with far more knowledge can give me some basic pointers for my specific case so I can research it more fully.
Basically part of my database is storing properties, then there's a separate table for property photos as each property can have between 0 and infinity photos (theoretically, the max. is likely to be between 5 or 10).
From my understanding so far it will be best to store a path to each picture as a text field in the database as we're looking at 100+ photos easily from the start which I understand would cause a huge database using OLE linking.
I've got a couple of articles on how to take the path and display it as a picture on the form, not tried it yet but had a read through and it all seems fine.
What I need to ask is the best way to do a couple of things...
When viewing a property via a form is it easy-ish/possible to display thumbnails and captions for all the associated images? Could it then be set up so you could click each image to view it full size?
I need a slightly more user friendly way of adding the photos than just typing in file paths. What I imagine the cleanest way would be blank boxes which you'd click, get a Browse... window to pick the image then once you'd picked one it would place a thumbnail in the box, or something similar. However I'm not sure how well that would scale to a non-specific number of images (ie 0 - 10).
I have no fixed specifications for displaying/adding these images so if you have other ideas/ways of doing it then please suggest - the above is just what I imagine would be 'nice' - if it involves way too much coding then it's not worth it at this stage.
Any help / pointers would be most appreciated :) Let me know if you need more info.
Chris :)
View 1 Replies
View Related
Nov 5, 2007
I'm responsible for an Access 2000 database which three people have open more or less constantly and another four open from time to time.
The database is on a P2P network and is split, with the back end in a single location. The network is wireless.
At the moment there are no problems with this setup but changes are being contemplated which will mean that eight people will have the database open constantly with another four using it occasionally.
For other reasons ( There were only three other wireless networks within range when we started, now there are eight), we are switching the network from wireless to cable. The back end will be transferred to a new PC with a powerful processor and loads of memory.
Does anyone have experience of allowing that many users to log on at the same time in a P2P network? And was the experience good or bad?
View 6 Replies
View Related
Dec 10, 2007
Any suggestions on how to handle delimiters when creating an SQL query string?There's a query form with a number of text boxes. User can enter text in one or more boxes. The VBA code checks the text boxes and generates the query string from what's been entered.eg. strSQLString = "SELECT * FROM [myTable] WHERE [Surname] = ' " & txtSurname & " ' "If the user enters a name such as O'Neil this will result in an invalid SQLString because of mis-matched single quotes."SELECT * FROM [myTable] WHERE [Surname] = ' O ' Neil ' "How can I handle input text which may contain delimiters?
View 3 Replies
View Related
May 4, 2007
Hi,
Thanks buddies for all ur help for the threads that i posted earlier!!
Again i have some questions..
The form that i created is one that shows records that are not in a particular table , once its updated to the table through a submit button on the form, it does not appear on the form (meaning, the form shows only ones that are still not been processed,)
so finaaly when it reaches the end of file, the form becomes blank and "ACCESS says it had encountered an error and needs to close" and creates backup copy..i dont want this to happen when the users use it.
I tried giving a recordset.Eof condition , when true giving a message to the user that "all have been done", but as soon as it jumps into that if block when it reaches EOF condition Access Pops up that message, How to solve this???
Thanks very much in advance!!!
View 7 Replies
View Related
Nov 4, 2014
I have below table in SQL Server which i have linked to MS Access 2010.
Create table test
(
col1 int not null
col2 int not null
)
Insert into Test values (1,2)
Insert into Test values (1,'')
Now when i link the table to access database and open up the table i dont have any issues with that. I tried to copy the test table data from access table and paste it to another access table which is linked to sql server with same schema structure thats when it says "You tried to assign the NULL value to a variable that is not a variant data type"..Its treating the blanks as NULLS when copy/paste the records from one table in access to another.
View 5 Replies
View Related
Oct 14, 2004
Here is my problem:
I have a database which we use to track customer orders of products that we provide to agents to sell to their customers. We have to keep track of the end-customer for redemptions/cancellations, and pay commissions to agents based on sales.
So, I have a Customer Table, Product Table, Order Table, and Agent Table. These are all tied together via the Order Table (Each Customer buys a Product from an Agent and this is known as an "Order").
We occasionally change the commission levels to the agents and the cost of the Products. However, these are mostly fixed costs and they apply across the board to all products of a type sold by that Agent. We institute changes as of a particular time period (all products sold after October 1st will cost $, etc.)
My concern is that if I change a price or commission now, it effects the commission and income reports for all time periods prior to that when the price change wasn't in effect. So if the price change takes place in October, I don't want that change to cascade to August orders.
I'm thinking that I need a price table with a date range in it and the ability to associate that with commissions and prices. I'm thinking I may have to further distinguish between prices and commissions, but I'm not sure. I'm sure that this issue has been addressed before (hopefully by someone on this forum :) ) and am looking for advice on setting this up.
View 4 Replies
View Related
Apr 28, 2014
I have a field where I'm recording the flashpoint of materials. The majority of the time, I'll have an actual number of the flashpoint (e.g. 100 or 140 or 200) but sometimes, I won't have a number or a number is not applicable.
Is using a combo box the only way to integrate an "N/A" solution for this? Otherwise, I'll have a field for the flashpoint and a second field for "NA".
View 14 Replies
View Related
Aug 23, 2011
I've got this database that needs some users to be read only and some users to have full control. I applied the appropriate ntfs permissions but there is a problem. If a read only users open the database, and then a full control users opens the database its stuck in read-only.
The database is a 2007 accdb.
View 2 Replies
View Related
Oct 7, 2015
I am putting together a "Clients" table, what is the best way to handle Clients with the same name.
For example:
Here are a few fields from my "Clients table":
ClientID
Fname
Mname
Lname
DateOfBirth
I was thinking of making a unique index for first and last, but then i thought, what if I come across 2 John Smith's?
I am sure there is a professional way of handling this, but Im not sure what the norm is.
-SHould I make a unique index for Fname, Mname, & Lname?
-SHould I make a unique index for Fname, Lname, & DateOfBirth?
I would like to know what is the norm when storing people in a table and the best way to prevent duplicate clients from being entered.
View 5 Replies
View Related
Sep 20, 2006
I manage a training database that tracks many different facets of an organization's training needs. One thing I would like to see is something that shows how many people will be in training on any given day. For example, I would like to see a range of dates printed down one column, and in the next column the number of people in training. I'm not sure how to best do this, so I'd appreciate any help or guidance.
To give you all a little background:
- Classes can last several months
- I would like to be able to create a class, including the class name and the date range of the class
- I would then like to be able to attach multiple people to the classes
- I would then like to be able to look at a report like I discussed above, that counts how many people are in any class on any given day
- I currently have a table for all of the people in my organization (keyed by HRID).
- I imagine a table for each class, including the Class Name and Date Range (would I have to do each date as a separate field??).
- The final table would include HRID and Class Name to link the two tables and "put people into a class."
I'm really struggling with how to handle the date range, particularly considering each class may go on for 60+ days. Does anyone know how to do this?
Thank you in advance!
View 5 Replies
View Related
Jan 29, 2008
Hi there !
I display some buttons on my Form. I should do an SQL request to know how many and what the button should display. It works fine with a RecordSet.
Now I want to move the code that do the stuff to a function. I read that I can't return a pointer to a RecordSet and I should used a variant with a getrows.
So I try this :
*here is my function
Function get_nom_operation(ByVal cnn As ADODB.connection) As Variant
Dim requetteSQL As String
Dim rst As New ADODB.Recordset
requetteSQL = "SELECT libelle " _
& "FROM operation;" _
rst.Open requetteSQL, cnn
get_nom_operation = rst.GetRows
End Function
* and here is the code that call the function
Dim res As Variant
Set res = get_nom_operation(conn)
Dim i As Integer
'i = 1
For i = LBound(res) To UBound(res)
Set Obj = Me.Controls.Add("forms.CommandButton.1")
With Obj
.Name = "monButton" & i
.Object.Caption = res(0,i)
.Left = 14
.Top = 25 * i
.Width = 60
.Height = 20
End With
'ajout de l'objet dans la classe
Set Ge = New gere_event
Set Ge.CButton = Obj
Collect.Add Ge
i = i + 1
Next
But it doesn' work, and I don't know why...
The error doesn't show where the code is stoped, but only show the call to display this form.
someone could show me some way to find the solution please ?
Thanks a lot.
View 1 Replies
View Related
Jul 13, 2006
What is the best way to handle Domestic vs. International customer information?
Such as Address and Phone Numbers.
Here in the US, we format like so:
Phone:
(888) 888-8888
Address:
Address1
Address2
City
State
ZIP (5 digit number only)
I know this only works in the US, what is a good model to use for allowing international information entry?
Is this post going down the right path: http://www.access-programmers.co.uk/forums/showthread.php?t=66149&highlight=domestic+international
Or is there better suggestions on the matter out there? Thanks!!!
View 2 Replies
View Related
Jan 11, 2006
I need to create a program that will regularly import a text file of over one million records into an Access table. I've been give a list of about fifty different updates to perform on the data to clean it.
I can't imagine performing all these updates in one query. However, creating fifty individual queries seems horribly inefficient from a processing perspective.
I'm accustomed to stepping sequentially through a table in FoxPro, which seems ideal to me for this type of situation. What is the best way to handle this in Access?
View 4 Replies
View Related
Apr 16, 2015
code for the "Forgot Password?" button on a login screen? I want an email notification sent to me if someone has forgotten their password, and/or automatically reset their password to a default value based on their user name.
View 4 Replies
View Related
Jul 21, 2007
I'm attempting to normalize an enormous table with order data, but I'm running into some problems. The table currently contains many duplicates, of which also included the actual order information (yikes!), but I managed to normalize it almost all the way down. It appears that different accounts can be used on orders, and these order numbers are being recycled for some reason months down the line (don't ask my why they're reusing them for future orders because I have no idea either, they should be creating new order numbers). Of course, the Order number is the primary key in my table as it should be. I guess the same thing can occur with the sales rep. Anyway, I'm struggling to find the "best practice way" to deal with this situation. I'm almost tempted to create an intermediary "transaction table" or something like that between the main general order information (which at this point will basically be the Order Number and Customer ID only), then include a table with the account information and sales rep info, then have that link to the Order Detail with the products, quantity, order number and various dates for those order numbers. Order maybe it should be a separate, related table, but not between the general order information and the order details? Can anyone tell me if I'm on the right track for this situation? It was a total curveball that the rep and account information could be different on these orders.
Option 1:
Order (Order #, Customer) -> Transaction Information (Order #, Account Type, Sales Person) -> Order Details (dates, products, quantities, etc)
Option 2:
Order (Order #, Customer)---> Transaction Information (Order #, Account
| Type, Sales Person)
|
|-> Order Details (dates, products, quantities, etc)
View 2 Replies
View Related
Jun 3, 2005
:confused: I need to find a way using macros to accomplish this task: I am trying to set the LimitToList property as a YES, and enter data that is not in the list already, but instead of the NotInList property giving me the following error "The item you entered is not in the list. Please choose one from the contents of the drop down box", I want to branch to a macro entered at theNotInList property to branch to that will eliminate the error, and give me the opportunity to enter my own message with options for the user to enter the item into the list, or try to choose an item from the drop down box instead. I want to do this with a macro if possible. I have seen many VB solutions that purport to solve the issue, but to be honest, I am not very well versed in VB procedures. That's why I would like to do it with a macro. I am very competent with macro procedures! Please help ASAP. Thanks.
View 1 Replies
View Related
Jun 30, 2014
A have a report that is based on a query that works fine when the query returns records.
However if the query (legitimately) returns no records then the report fields (numeric) are blank.
How can i get the query or report to show either "0" or "no data" when no records are returned? I have tried the NZ function but that didn't work so i don't think that is the right approach here?
View 3 Replies
View Related
May 7, 2013
In Access 2010, I'm writing VBA code that assigns an ADO dataset as the recordsource for a form. The query itself varies and is constructed from a search term typed in a textbox by the user. The code below works perfectly until the dataset is empty, when no records satisfied the WHERE criteria. In that case, there is a very long pause (presumably a timeout?) and I eventually get the error message "ODBC call failed." I tried to get around this by testing the number of records in the dataset (see toward the end) before assigning it, but it makes no difference in the behavior, so I'm thinking the actual assignment isn't the issue ... something else is.
If it matters, the "FROM qry_beneficial_owners" in this case is predefined query local to my Access db. That query is based on a linked view from a SQL server.
Code:
Public Sub RunSearch(SearchTerm As String)
Dim cn As ADODB.Connection
Dim rs As ADODB.Recordset
Dim sql As String
Dim cols As String
cols = "[acct], [acctname], [planid]"
[Code] ....
View 1 Replies
View Related