Using Win32 functions in Visual FoxPro Image Gallery
Code examples:
Loading a string resource from an executable file
Pocket PC: Folder Viewer
Removing FTP directory
Scanning the hierarchy of child windows down from the main VFP window
Setting properties of the window: caption and user-defined value
Using an Event Object. Part B: running an application responding to events
Using custom Simple MapiSendMail class
Validating URLs using moniker functions
Converting an integer value to a hexadecimal string
Customizing the frame of top-level form: removing the standard frame (VFP9, Vista)
How to generate GUID values
How to read email messages using Simple MAPI
Memory usage info for current VFP session (WinNT only)
Playing WAV sounds simultaneously
Winsock: retrieving the host information corresponding to a network address
Comparing file times
Determining if an Active Network Connection is Available
Enumerating ODBC drivers available on the local computer
How to run FoxPro application under different user name (impersonating user)
Printing text on the client area of the main VFP window
Reading parameters of streams in AVI file
Retrieving graphic capabilities of default printer
Testing Transparent Menu Class with top-level form (requires VFP9)
Retrieveing information about the active window (even if it is not owned by the calling process)
How to generate UUID values

User rating: 0/10 (0 votes)
Rate this code sample:
  • ~
More code examples    Listed functions    Add comment     W32 Constants      Translate this page Printer friendly version of this code sample
Versions:
click to open
Before you begin:
See also:
  • How to generate GUID values
  •  
    FOR nIndex=1 TO 10
        ? GetUUID()
    NEXT
    * end of main
     
    PROCEDURE GetUUID()
        DECLARE INTEGER UuidCreate IN Rpcrt4 STRING @Uuid
        DECLARE INTEGER RpcStringFree IN Rpcrt4 LONG @StringUuid
     
        DECLARE INTEGER UuidToString IN Rpcrt4;
            STRING @Uuid, LONG @StringUuid
     
        DECLARE RtlMoveMemory IN kernel32 As MemToStr;
            STRING @, INTEGER, INTEGER
     
        LOCAL cUUID, hBuffer, nBufsize, cResult
        cResult=""
        hBuffer=0
        cUUID=REPLICATE(CHR(0), 16)
     
        = UuidCreate(@cUUID)
     
        IF UuidToString(@cUUID, @hBuffer)=0
            nBufsize=36
            cResult=REPLICATE(CHR(0), nBufsize)
            MemToStr(@cResult, hBuffer, nBufsize)
            RpcStringFree(@hBuffer)
        ENDIF
        cResult=UPPER(STRTRAN(m.cResult, CHR(0), ""))
    RETURN m.cResult
     

    User rating: 0/10 (0 votes)
    Rate this code sample:
    • ~
    706 bytes  
    Created: 2001-07-12 12:00:00  
    Modified: 2010-01-27 10:32:01  
    Visits in 7 days: 58  
    Listed functions:
    RpcStringFree
    UuidCreate
    UuidToString
    Printer friendly API declarations
    Word Index links for this example:
    Translate this page:
      Spanish    Portuguese    German    French    Italian  
    FreeTranslation.com offers instant, free translations of text or web pages.
    User Contributed Notes:
    There are no notes on this subject.


    Copyright © 2001-2013 News2News, Inc. Before reproducing or distributing any data from this site please ask for an approval from its owner. Unless otherwise specified, this page is for your personal and non-commercial use. The information on this page is presented AS IS, meaning that you may use it at your own risk. Microsoft Visual FoxPro and Windows are trade marks of Microsoft Corp. All other trademarks are the property of their respective owners. 

    Privacy policy
    Credits: PHP (4.4.9), an HTML-embedded scripting language, MySQL (5.1.55-log), the Open Source standard SQL database, AceHTML Freeware Version 4, freeware HTML Editor of choice.   Hosted by Korax Online Inc.
    Last Topics Visited (184.72.184.104)
    1.61 hrs.Function: 'GetProcessHeap'
     Example: 'How to create MD-5 and SHA-1 hash values from a string'
     Function: 'GetProcessIoCounters'
    Function group: 'Process and Thread'
    4.39 hrs.Example: 'How to view icons stored in executable files (Icon Viewer)'
    5.19 hrs.Function: 'SQLNativeSql'
     Example: 'Obtaining list of tables stored in an ODBC Data Source'
    6 hrs.Function: 'OpenWaitableTimer'
    Function group: 'Synchronization'
     Example: 'Accessing Adobe Reader 7.0 main menu from VFP application'
    12.87 hrs.Function: 'CloseEnhMetaFile'
     Example: 'Managing Cookies'
    Google
    Advertise here!