Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Using AddressOf function in Access97 VBA

Posted on 1998-07-09
4
Medium Priority
?
1,007 Views
Last Modified: 2012-08-13
I'm using the following code in my database to sort a listview control..

SendMessage axLV1.hWnd, LVM_SORTITEMS, axLV1.hWnd, AddressOf CompareDates
and each and every time i want to write this line, in any fashion i could imagine, access responded me Expected : Expression..

When i write AddressOf and i press space, Access gives me suggestions on the function names i can use and i use one of them, but Access keeps telling me that it expects an expression... !!!  Help me please !!

0
Comment
Question by:little_
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 

Author Comment

by:little_
ID: 1976442
Edited text of question
0
 
LVL 12

Expert Comment

by:Trygve
ID: 1976443
Do you have the CompareDates function in your application ?
0
 

Author Comment

by:little_
ID: 1976444
Yes, the function exists.  When i press the space bar after writing the addressof expression, the function i want to uses is part of the choices in the list.
0
 
LVL 4

Accepted Solution

by:
tomook earned 100 total points
ID: 1976445
The Declare statement for SendMessage must define the parameter to receive the AddressOf "As Any". If this is not it, please post the declaration for SendMessage and CompareDates.
0

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In Part II of this series, I will discuss how to identify all open instances of Excel and enumerate the workbooks, spreadsheets, and named ranges within each of those instances.
Did you know that more than 4 billion data records have been recorded as lost or stolen since 2013? It was a staggering number brought to our attention during last week’s ManageEngine webinar, where attendees received a comprehensive look at the ma…
Learn how to number pages in an Access report over each group. Activate two pass printing by referencing the pages property: Add code to the Page Footers OnFormat event to capture the pages as there occur for each group. Use the pages property to …
In Microsoft Access, learn how to use Dlookup and other domain aggregate functions and one method of specifying a string value within a string. Specify the first argument, which is the expression to be returned: Specify the second argument, which …

596 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question