Results 1 to 4 of 4

Thread: basics of windows using API

  1. #1

    Thread Starter
    PowerPoster make me rain's Avatar
    Join Date
    Sep 2008
    Location
    india/Hubli
    Posts
    2,208

    Question basics of windows using API

    i have seen & copied many windows API code snippets in this forum
    but i didn't know what they are & how the job they do
    even i purchased some books but i could not follow the H00&
    etc hexa codes. i don't know C.
    on asking some one they told me that " Oh it is very simple! and to know English is it necessary to know German !?* forget C.,,, etc)
    please guide me with some basic tutorials if any please.

    thank u all.

  2. #2
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: basics of windows using API

    Moved From The Classic VB CodeBank

  3. #3
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 2002
    Location
    Bristol, UK
    Posts
    41,974

    Re: basics of windows using API

    You do not need to know C - it is almost completely irrelevant.


    To find out what an API function does, read the official documentation for it (but ignore any code, as the examples are C!):
    http://msdn.microsoft.com/en-us/libr...88(VS.85).aspx

    To get a VB example, check out this site:
    http://allapi.mentalis.org/apilist/apilist.php
    ...and/or search the forums.



    Things like &H12 are actually just numbers - the &H means that the numbers/letters after it are a number in Hexadecimal (16 possible values per digit), rather than normal Decimal numbers (10 possible values per digit).

    If they have & at the end too (eg: &H12&), that just means to use a data type of Long, rather than what VB would pick by default.

    If you use a calculator (or use MsgBox in VB code), you will see that &H12 (Hexadecimal 12) is 18 in Decimal.

    Note that if you want to use the numbers from the Microsoft documentation, you just need to change the first two digits from 0x to &H

  4. #4
    Super Moderator Shaggy Hiker's Avatar
    Join Date
    Aug 2002
    Location
    Idaho
    Posts
    40,104

    Re: basics of windows using API

    There's also a handy Hex -> Decimal -> Binary converter in the built-in calculator that ships with windows, just select the Scientific option for the calculator.
    My usual boring signature: Nothing

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width