IIf Or An Alternative Function.

Nov 23, 2007

In a table with 5000 records there is a field named "products" with 800 differents products (product1, product2, … product800).
I want to create a new field in a query and mark 100 of these products as "Not available" and the rest 700 as "Available".
For a small number of products I can do this in QBA, using IIf function.
E.g. Products not available:IIf([products] ="product5";"Not available"; IIf([products] ="product10";"Not available"; IIf([products] ="product22";"Not available";"Available"))).
How can I do this for 100 products
Thank you.

View Replies


ADVERTISEMENT

Alternative To Replication?

Dec 15, 2005

I am having multiple user problems with access 2000 quite frequently, and I thought that replication would solve this, as it stands however its proving difficult to get my hands on the developer edition, just wondering, is it worth the hassle to get it, or is there an effective alternative to replication?

View 6 Replies View Related

Is There Alternative For This Code

Feb 22, 2006

The following is loaded in a query:

The field is called CS:
Like [Enter Specialist Last Name Only] & "*"

It works ok, but of course if you don't type anything it will bring all the records up for view, and I don't want that to happen. Can I do something that won't make that happen?

View 4 Replies View Related

DDESend Or An Alternative

Jan 23, 2008

I want to be able to use something like DDESend for putting data into word bookmarks. I already have several instances where this is done with code but I need some others with a simple thing like DDESend.

The problem I have with DDESend is when the form opens a box pops up asking if the Word file is to be opened. I tried with code to first open the Word.doc file and then have the code open the form with the DDESend text boxes but that ends opening two instances of the same Word.doc and the screen all quivers:D

If I just open the form in question and then click OK to open the Word.doc, then close and reopen the form (but without closing the Word.doc, just shrinking it) then all is well. But it is not practical to do that for what is wanted.

Any ideas or an alternative to DDESend. An alternative would need to be simple like a DDESend in text box as it requires someone to be able to easily change field references.

View 2 Replies View Related

Alternative To Listbox?

Oct 9, 2007

Hello

I am designing a database in which I have used a lot of listboxes sourced to tables. I need to run queries on the listbox results but this doesn't always work due to the listbox/query issue, (found on this forum).

Is there an acceptable alternative to listboxes as the only thing that I can think of is to use checkboxes which would make the data entry for the end user interesting? (The only way around this would be to have individual databases for each person, this defeats the objective of having a database...)

Many thanks

Loopster

View 3 Replies View Related

Alternative SQL Query

Jun 19, 2007

I have a query worked out with the exact result I'm looking for, but it's kind of slow. Can someone find another way to write up this query?SELECT EID, ShortName, ClassID
FROM (
SELECT Employee.EID, Class.CID, Class.ShortName
FROM Employee, Class
) AS Temp1
LEFT JOIN [Class Attendance]
ON (Temp1.CID=[Class Attendance].ClassID) AND
(Temp1.EID=[Class Attendance].EmployeeID);The inner (green) query pairs every employee with every class they could possibly take (cross product). Then that query is joined with the attendance table to show who has taken which class. If a class hasn't been taken the ClassID will be null like so:EID ClassID ShortName
=========================
111-11-1111 1 ISM
111-11-1111 2 ABC
111-11-1111 BGP
222-22-2222 ISM
222-22-2222 2 ABC
222-22-2222 3 BGPSo is there an easier way to get this result?

View 4 Replies View Related

Alternative Printer

Nov 6, 2006

I wish to send a report to the PDF printer driver but DO NOT wish to switch the default printer settings. Having found some helpful code on this forum that changes the default printer to the PDF driver, prints the job and then reverts the default printer back to the original printer device.

I am still using Access '97 and although in the code, the default printer does revert back to what it was originally, the Default Printer status 'tick' no longer appears under Start/Settings/Printers.... Consequently, subsequent print jobs outside of Access go to another device and not my DEFAULT printer.......???

Any ideas would be gratefully appreciated.

Oh - in case I wasnt clear - I want to do this in code NOT using the Print dialog box.... !

View 1 Replies View Related

MS FlexGrid Or Alternative

Mar 14, 2006

Hi,

Can I use MS Flexgrid in MS access ? When I try to use it, it shows I need licence. Is there any alternate method to use flexgrid or is there any alternative ? Basically, I need to facilitate edit and save option for users. Urgent help required ?

View 6 Replies View Related

Alternative To Application.FollowHyperlink

Jul 28, 2005

Hi!

I have a helpfile that I want to open on a Event. But when i use Application.FollowHyperlink I get an annoying warning (the file can contain viruses or in other ways damage your computer) so I wonder if there is another alternative to Application.FollowHyperlink?

Thanks,
Johan Hjalmarsson

View 1 Replies View Related

Alternative Colours In A Form

Mar 15, 2005

Hi I've got some code from http://www.lebans.com/alternatecolordetailsection.htm

It allows for alternate bands of color to be displayed for alternative records in Forms in Continuous View. I've looked in this forum for other alternatives to this but the only ones that are available change the background of a control rather that display a whole row that is filled with colour. So therefore the background of the row is say in red, the background of the text controls are in red.

I've managed to put the code into my form and download the class. The only problem is that I can't seem to set the colour in the actual class file - it's all a little bit confusing! Can you help? Pleaseeeeeeeeeeeeeeeeeeeeeee........... :D

You can download the sample database from http://www.lebans.com/alternatecolordetailsection.htm

:)

View 1 Replies View Related

Help Needed With Security Alternative

Jul 28, 2006

Hi

I have a custom login screen created for my database and a table with access levels for different users. I am trying to assign user permissions so that certain buttons on the switchboard are visible/not visible dependent on the user security level. As the login screen and the switchboard are on seperate forms, is there any way I can do this??

I've been pulling my hair out since last night so any help at all would be appreaciated

cheers

View 8 Replies View Related

Workgroup Security Alternative?

Apr 21, 2005

I was looking for free access add-ins through a search engine when I came across this site. I'm not sure whether or not some of the more seasoned programmers have seen this, but so far it looks like a less confusing alternative to the security features that access comes with. I'm not in any way advertising this, and I haven't tried it myself yet, so I can't speak about how good or bad it is, but it may be something worth looking into. Here are the links:

http://www.accesswizards.com/Downloads.html This lists the add-ins that are available from this particular site.

http://www.accesswizards.com/SecDetails.html This is the "read me" information about the security add-in.

View 1 Replies View Related

Can't Create MDE File - Alternative

Dec 7, 2005

I have tried to create an MDE file for my database but can't figure out why it will not let me. I can't don't think I am over the limit in open TableIDs. I have 76 Forms and 91 Tables.

I am setup with two databases - the database with the data is on the server. Is there any other alternative that I can do other than putting the mdb file directly on the client. And if not is there a way to stop the mdb file from constantly growing in size.

View 4 Replies View Related

Subdatasheet Not Sufficient, Please Give Alternative

Dec 28, 2004

What I am doing, is I have various products with 5 basic fields. I then wanted to add an array of text fields to 2 of those original 5 basic fields. I attempted to do this with a subdatasheet, however, a subdatasheet is not record specific, is not directed to a specific field, and really does not do anything that I want.

Say that the basic field is ProductDescription. I want one column of fields to correlate to it, like below.
ProductDescription
Is blue
Is large
Is heavy
Is strong

Each product will have a different amount of varying descriptor fields. Once understand how to incorporate this with my project, I then will need to understand how to add the subdatasheet to a report easily. Thanks for any help,
-SethTherrien

View 3 Replies View Related

Populating Form - Combo Box Or Alternative?

Aug 28, 2006

If any one can make a suggestion it would be great. I have a list of names with phone numbers, addresses and emails. I thought I could use a combo box to select the name and and have the other date associated with it come up in the appropriate boxes set. I can't get it to work. Does any one have any suggestions on how to make it work or another method that can be used. The out come I want is to allow someone to pic name from a list which will then set the phone number, address and email correct. Ideas would be great.

Thanks Tracey

View 1 Replies View Related

Forms :: Alternative To Combo Box And List Box?

May 6, 2015

I am trying to avoid to use a Combo Box & a List Box because of the way the records are stored in the table, I only need to verify that the user does not enter a 3 letter code that is not contained in a specific table (I have a table of countries with the 3 letter code example if the user types ESC instead of ESP an error appears) Is it possible to use the after update to verify the contents against a table?

View 4 Replies View Related

General :: Saving Records In Alternative DB?

Jul 6, 2012

I have a stock db with records that go back to 2006. I want to clear some of the old records but save them incase required. I still need to leave from 2010 until present on the db. I have a front and back end on the db.

View 1 Replies View Related

General :: Change Splash Screen For Database Using Method Of Creating Alternative Bitmap

Oct 17, 2014

I've changed my splash screen for a database using the method of creating an alternative bitmap.Is there a time setting for this or an alternative?

View 6 Replies View Related

Modules & VBA :: Creating A Function That Counts Records And Use That Function In A Query

Dec 11, 2013

So basically I need making a function that will count the number of records from another table/query based on a field from the current query.

View 2 Replies View Related

Forms :: SUM Function Produces Error From Calculated Function

Jan 30, 2014

I have a project at hand and it's been a predecessor of mine and client has asked me to do some work on it and extend functionality - but I have not really delved into Access before and I have had to worked my way through to this final snag :/

The Main Form has one sub form. This sub form allows the user to add multiple order items i.e. qty, stock, description from records within the system - fairly straight forward.At the last column of each row is the sub total of those particular items i.e.

Qty Unit | Item ID | Total
-----------------------
2 | 1234 | 80.00
------------------------
1 | 43526 | 20.00
------------------------
> | |

So the total is a function of =[Qty Unit] * [Unit Price].Then in the Footer of this SubForm is the Sub Total

=SUM([Qty Unit] * [Unit Price])

All fine and well..... However, the additional functionality kicks in.

Lets add the additional customer_id from the Main Form. Each Item bought is dependent on the customer_id i.e. they get special prices depending on who they are.So a New table is made which has the Item ID and SpecialPriceID (of a table to define as a specialPrice) and the Price linked to this Item and Special Price category. So say that there are two groups of users "wholesale" and "nonwholesale" these would be SP_1 and SP_2 and each client is defined either one of these, and each stock item has a Price for each SP_1 and SP_2. Hopefully I've explained myself there.

Back to the SubForm. So now the Total needs to calculated differently with needed the external customer_id from the Main Form.

Code:

Function CalculateSpecialPrice(ItemID As String, CustomerID As String, Unit As Integer)
Dim SPSelect As String
SPSelect = "SELECT Price FROM [Items_SpecialPrices] WHERE"
SPSelect = SPSelect & " ItemID = '" & ItemID
SPSelect = SPSelect & "' AND SpecialPriceID = (SELECT SpecialPriceID FROM Customers WHERE customer_id = " & CustomerID & ") "

[code]....

its the sub total I just keep on getting #Error on. I have even watched (using alerts) that the correct return variable is the same as the individual rows. This is the equation I used for the SubTotal within the footer.

=SUM(CalculateSpecialPrice([Item ID], [Form]![FormName]![CustomerID], [Qty Unit]))
#Error

View 2 Replies View Related

Date Function/need Time Function

Jun 9, 2005

We have a date function that converts a text date format. Can someone help me with time function to do the same thing? We want military time. The field is like this now: txt fields.
160037
213137
224356
235716
235800
12341
21708
22732
Here is the date function we use:
Function f2Date(strDateOld As String)
Dim strDate As String, strMonth As String, strYear As String
strMonth = Mid(strDateOld, 5, 2)
strDate = Right(strDateOld, 2)
strYear = Left(strDateOld, 4)
f2Date = strMonth & "-" & strDate & "-" & strYear
f2Date = CDate(f2Date)
f2Date = Format(f2Date, "mmmm d yyyy")
End Function

View 9 Replies View Related

Now Function To Convert To Date Function

May 25, 2006

Hi all,

I need a little help. In my DB, I have a command button set up (I was tired of typing in dates) for date, but I used the Now function, which also gives me the time.

Now I have over 3000 subrecords of the main ones. I now need to queries transaction for that specific date, but it also retrieves the time.

I tried to go back and change the NOW to DATE in VB, but the code does not run.

How do I change all records that have date and time (using NOW function) and only click that command button to show only the date (mm/dd/yyyy)?

Thanks in advance.

View 1 Replies View Related

Function

Aug 1, 2005

Is there any function that can convert either a True, False, "Yes", "No" or Null value.... to a yes/no (check box) data type?

What I want to do is create a make table query. I would like to add a checkbox field from the query. So if there was a function that could convert a data type to a Yes/No checkbox, this would be very helpful...

To give you and idea of what I'm talking about...and how I want to use this... If I am making a table from a query and I want to add a number field, but leave it empty for the time being, what I can do is make a new field in the query maybe call it "Number1". What I would do is Add this as a field in my make table query:

Number1: Cint("")


This will add a blank field that is formatted as a number field when I run the make table query.

So using the same logic, I'd like to make a blank (or unchecked) Yes/No check box field when I run my make table query.

Anyway...that's what I'm hoping for.... I hope someone can help!

Gary

View 10 Replies View Related

Function Isn't Available

Nov 3, 2005

I'm having a problem getting a form to open. I'm using access 97 on on XP machine and whan I open my database I get Function isn't available in expressions in query expression '[Case Types]![theName]&"-"&Format([SourceDocs]![CaseNumber]&"","00")&"-"&Format([SourceDocs]![CaseYear]&"","00")'.

This database works fine on a Windows 2000 machine running Access 97 but none of the XP machines will open it.

Any suggestions?

Thanks,
Rick

View 8 Replies View Related

CHR() Function Not Available

Nov 10, 2006

I have a database in which I am designing a report which includes a name/address block. I am surprised to find that the report does not recognise the Chr() function in the text box control source string "=[Organisation] & Chr(13) & Chr(10) & [Address]..."; designed to insert a CRLF between the contents of the named fields.

I know the syntax is correct because I've checked by using the expression builder to replicate the code. (Expression builder includes the Chr() function, as expected.)

The interesting thing is that the function is recognised in other databases used on the same machine, both those created remotely and locally.

Anyone know what could be going wrong?

Stuart

View 7 Replies View Related

Function Is Not Available

Sep 4, 2005

I am using a crosstab query to gather info from a table. I am using the Format [DateAppt], "mmm". The query ran successfully before but I now get the error "Function is not abailable in expression in query expression 'Format ([DateAppt], "mmm")'. This is used for column headings in a report that gives results by month.

I am using Microsft Office 2000 Premium with XP Professional operating system.

I used the original disk to repair Office thinking that the function was missing from the function library but to no avail.

Does anyone know how to restore this function?

Thank you,
Jack

View 1 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved