Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Modules / DAO / VBA / December 2005

Tip: Looking for answers? Try searching our database.

Domain function in Access 2000

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Del - 20 Dec 2005 16:10 GMT
I'm using Access 2000 with XP.

How can I detemine the biggest number in a text field that has both number
records and text records in it?  When I use Dmax function I get the following
error "Run time error 13: Type Mismatch"
Signature

Thank you,
Del

fredg - 20 Dec 2005 17:35 GMT
> I'm using Access 2000 with XP.
>
> How can I detemine the biggest number in a text field that has both number
> records and text records in it?  When I use Dmax function I get the following
> error "Run time error 13: Type Mismatch"

A text field is text. Any number in a text field is still text.
Would you care to give us several examples of your actual data in the
field?

Signature

Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail

Del - 20 Dec 2005 18:50 GMT
I work in a manufacturing environment.  We have several departments that each
have several lines of mfg equipment.  Each line is identified with a number,
i.e. the surface mount department has 4 lines of equipment and these lines
are called 1, 2, 3, & 4.  I am building a database application to track the
scheduled maintenance on all this equipment.  One of my tables contains a
list of all the departments and any lines associated with them.  So, when I'm
entering a new piece of equipment I can select the appropriate line to help
ID that equipment.  When we add a new line I want my code to add 1 to the
biggest number associated with that department to generate the new line
number.  This would work fine if I didn't need to add "N/A" to the list for
pieces of equipment in these departments that are not assigned to a line.  
It's the N/A that causes the error (mentioned in my first post) when I use
DMax function to find the biggest number.

Here is an example of the data in the two fields in the table.

Dept               Line
SMT                N/A
SMT                 1
SMT                 2
SMT                 3
SMT                 4
AI                    N/A
AI                     1
AI                     2
AI                     3

Signature

Thank you,
Del

> > I'm using Access 2000 with XP.
> >
[quoted text clipped - 5 lines]
> Would you care to give us several examples of your actual data in the
> field?
Del - 20 Dec 2005 19:31 GMT
Please excuse my blindness.

I simply need to exclude "N/A" in the criteria
Signature

Thank you,
Del

> > I'm using Access 2000 with XP.
> >
[quoted text clipped - 5 lines]
> Would you care to give us several examples of your actual data in the
> field?
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.