After developing an MDB in Access 2003 on WS03, then making it into an MDE
and deploying it on a WinXP box with Access 2003 installed, I get this
error:
Function is not available in expressions in query expression
[below is full query that appears in part in the error message]
SELECT IIf(IsNull([Address1]),"",[Address1] & Chr(13) & Char(10)) &
IIf(IsNull([Address]),"",[Address] & Char(13) & Char(10)) &
IIf(IsNull([Address]),"",[Address] & Char(13) & Char(10)) &
IIf(IsNull([City]),"",] & IIf(IsNull([State]),"",", ") &
] & " " & [Zip]) & Char(13) & Char(10) &
IIf(IsNull([Country]),"",]) AS txtAddress, Add_ID
FROM bladders
WHERE Entity_ID=Wryer("form","Entity_ID")
ORDER BY Primary;
I searched the MS Knowledgebase, but found nothing. From what I've
discovered from other resources on the web, this may have something to do
with either the version of the Expression Service DLL, or an MDAC service
pack. I tried installing the latest JET service pack, but that did not help.
I also tried copying the expsrv.dll from the development box to the
deployment box, but that did not help. I'm wondering if this has anything to
do with other (seemingly unrelated) references. Here's a list of references
on the development box:
?ReferenceInfo
Reference: VBA
Location: C:\Program Files\Common Files\Microsoft Shared\VBA\VBA6\VBE6.DLL
Reference: Access
Location: C:\Program Files\Microsoft Office\OFFICE11\MSACC.OLB
Reference: stdole
Location: C:\WINDOWS\system32\stdole2.tab
Reference: DAO
Location: C:\Program Files\Common Files\Microsoft Shared\DAO\DAO360.DLL
Reference: ADODB
Location: C:\Program Files\Common Files\System\ado\msado25.tlb
Reference: Excel
Location: C:\Program Files\Microsoft Office\OFFICE11\EXCEL.EXE
Reference: Office
Location: C:\Program Files\Common Files\Microsoft Shared\OFFICE11\MSO.DLL
Reference: Outlook
Location: C:\Program Files\Microsoft Office\OFFICE11\msoutl.olb
Reference: Word
Location: C:\Program Files\Microsoft Office\OFFICE11\MSWORD.OLB
In an MDE, my understanding is that all of these are supposed to stick,
regardless of the client. If something is missing, the reference will appear
as MISSING: "whatever".
The reason I format the address in a query rather than in VBA is speed. As a
user scrolls through records in the database, each record's address appears
in a subform. Making this query the RecordSource of the subform is much
faster than using DLookup for the elements of the address. I'd hate to have
to rework the query, and would much rather figure out what's missing on the
target box so if I hit other deployment snags I'll know where to look.