Solved

GetGestureInfo entry point not in USER32.dll

Posted on 2014-03-19
2
865 Views
Last Modified: 2014-04-08
I make reference to GetGestureInfo in my app so that I can do some touchscreen things when the PC is so-enabled.  I only need it to work on win7 and win8.  But I can't even run my app on XP now because of the "entry point not found" error as in the title of this question.   So, what is a good way to avoid this?  I don't want a solution that requires a separate build for XP if at all possible.   Can I do something like put my call to GetGestureInfo in a DLL and then dynamically link that DLL only if I see I'm running on win7/8 ?  Something like that?  What is best/easiest way?  Thanks!

My app is MS C++ using a bit of MFC and using VS2010.
0
Comment
Question by:tullhead
[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 Comments
 

Author Comment

by:tullhead
ID: 39946851
Further to this.  So now I'm trying to put the call to GetGestureInfo in a dynamically linked DLL.  Then I just won't load it if I see that I'm on XP.  But I'm not too good at DLL and passing arguments to functions in them, and whats allowed and what isn't.

I try to allocate dynamically the GESTUREINFO in my main program, so that I have a pointer to it to pass to the function in the DLL -- is this going to work safely?  SO, in main program something like:
   
        GESTUREINFO* pgi = new GESTUREINFO();
         ZeroMemory(pgi, sizeof(GESTUREINFO));
         pgi->cbSize = sizeof(GESTUREINFO);

Then I try to call the function which is in the DLL:

        BOOL bResult = theApp.CallGetGestureInfo(lParam, pgi);

But its crashing.  Even if, in the DLL I don't even call GetGestureInfo -- as a test, I simply
have the function in the DLL return the BOOL "false".  Still, main program crashes.

What am I doing wrong?
0
 
LVL 34

Accepted Solution

by:
Duncan Roe earned 500 total points
ID: 39951778
You must expect this kind of problem when you develop for one revision and then seek to run on an older revision. The way you have approached it looks fine to me.
You need to debug this: after executing line 1, does pgi contain a valid memory pointer? What is sizeof GESTUREINFO? Does your GESTUREINFO::GESTUREINFO() allocate that much memory? Is pgi still good at the start of line 3? and so on.
After that, you need to debug your DLL
0

Featured Post

Resolve Critical IT Incidents Fast

If your data, services or processes become compromised, your organization can suffer damage in just minutes and how fast you communicate during a major IT incident is everything. Learn how to immediately identify incidents & best practices to resolve them quickly and effectively.

Question has a verified solution.

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

Suggested Solutions

Today, still in the boom of Apple, PC's and products, nearly 50% of the computer users use Windows as graphical operating systems. If you are among those users who love windows, but are grappling to keep the system's hard drive optimized, then you s…
Healthcare organizations in the United States must adhere to the guidance of both the HIPAA (Health Insurance Portability and Accountability Act) and HITECH (Health Information Technology for Economic and Clinical Health Act) for securing and protec…
This video demonstrates how to use each tool, their shortcuts, where and when to use them, and how to use the keyboard to improve workflow.
The viewer will learn how to successfully create a multiboot device using the SARDU utility on Windows 7. Start the SARDU utility: Change the image directory to wherever you store your ISOs, this will prevent you from having 2 copies of an ISO wit…

738 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