Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 232
  • Last Modified:

generic c++ +< windows.h>

http://www.codeproject.com/system/keyboard.asp

is it possible to make this function available to generic c++ without having to use visual studio?
0
Troudeloup
Asked:
Troudeloup
  • 4
  • 3
4 Solutions
 
jkrCommented:
Well, you will need windows.h for the declaration of 'keybd_event()' and all the constants used there. Apart from that, it should work with any compiler.
0
 
TroudeloupAuthor Commented:
method wise - the sample code cannot be used directly. right?

can you venture on a guess on how he accomplish this?

send ("hellow world!")


in a string and then automatically looked up codes for each symbol -


no wait, he could do string1[n]  and then replace each with codes he looks up!


" " = vk_space, or something


right?
0
 
evilrixSenior Software Engineer (Avast)Commented:
Unfortunately, in C++ there is no generic and cross platform (by this I mean the OS, not the compiler!) way to do such keyboard scanning as it is not defined by the standard. Each platform will provide it's own way to achieve this.
0
Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
TroudeloupAuthor Commented:
oh i should empasize that I want to use  kbevent  on windows with windows sdk!


i want to avoid visual studio for now.
0
 
evilrixSenior Software Engineer (Avast)Commented:
>> i want to avoid visual studio for now.
I have this strange feeling of deja vu :)

I don't know why you don't just prototype it using VS first and then; once you are more comfortable with what you are doing look to migrate to another compiler. I'm sure it'd be a lot less painful for you :)
0
 
TroudeloupAuthor Commented:
actually i have menu, children window, windows help, and terminology phobia and it's really bad.

i find dealing with only c++ code in text compiler with color coding a little less steep on the curve.

:D
0
 
evilrixSenior Software Engineer (Avast)Commented:
You are a strange one Troudeloup, but a source of much amusement :)
0
 
evilrixSenior Software Engineer (Avast)Commented:
:)
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

The 14th Annual Expert Award Winners

The results are in! Meet the top members of our 2017 Expert Awards. Congratulations to all who qualified!

  • 4
  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now