Using Win32 functions in Visual FoxPro Image Gallery
Shell Functions
..msdn
AssocQueryString
DllGetVersion
DragAcceptFiles
DragFinish
DragQueryFile
DragQueryPoint
FileIconInit
FindExecutable
GetFileNameFromBrowse
GetMenuContextHelpId
GetWindowContextHelpId
InetIsOffline
IsUserAnAdmin
LoadUserProfile
PathMakeUniqueName
PathYetAnotherMakeUniqueName
RealDriveType
RestartDialog
SHAddToRecentDocs
SHBrowseForFolder
SHCreateDirectory
ShellAbout
ShellExecute
ShellExecuteEx
Shell_GetImageLists
Shell_NotifyIcon
SHEmptyRecycleBin
SHFileOperation
SHFormatDrive
SHGetFileInfo
SHGetFolderPath
SHGetPathFromIDList
SHGetSpecialFolderLocation
SHGetStockIconInfo
SHParseDisplayName
SHQueryRecycleBin
SHSimpleIDListFromPath
UnloadUserProfile
WinHelp
Code examples:
Retrieving current user for the process
Retrieving current user for the process

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
Before you begin:
See also:
  • Function GetUserName
  • Function IsUserAnAdmin
  • Finding out if the current user is the Guest account
  • #DEFINE NO_ERROR 0
    
    DECLARE INTEGER IsUserAnAdmin IN shell32
    
    DECLARE INTEGER WNetGetUser IN mpr;
        INTEGER lpName, STRING @lpUserName, INTEGER @lpnLength
    
    LOCAL lcUser, lnBufsize
    lnBufsize = 250
    lcUser = Repli(Chr(0), lnBufsize)
    
    IF WNetGetUser(0, @lcUser, @lnBufsize) = NO_ERROR
        ? "Default user name:", SUBSTR(lcUser, 1, AT(Chr(0),lcUser)-1)
        ? "Is user and admin:", Iif(IsUserAnAdmin()=0, "No", "Yes")
    ENDIF
    
    
    

    User rating: 0/10 (0 votes)
    Rate this code sample:
    • ~
    428 bytes  
    Created: 2002-06-06 08:27:12  
    Modified: 2010-07-06 09:33:49  
    Visits in 7 days: 23  
    Listed functions:
    IsUserAnAdmin
    WNetGetUser
    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:
    decentrajan@gmail.com | 2006-12-15 02:20:14
    Hi frinds,
    how i get all network computers (currently working) on any of my computer. mean i want store all procesing computers in my table. is this is possible
    if yes please guide me. this is urgent

    regards
    Rajan

    Copyright 2001-2017 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.6.38), the Open Source standard SQL database, AceHTML Freeware Version 4, freeware HTML Editor of choice.   Hosted by Korax Online Inc.
    Last Topics Visited (54.162.139.105)
    3 sec.Project
    6 sec.Function: 'SQLGetInstalledDrivers'
    Function group: 'ODBC API'
    10 sec.
    Function group: 'Windows Controls'
    13 sec.Function: 'getprotobynumber'
    Function group: 'Windows Sockets 2 (Winsock)'
    16 sec.Function: 'midiOutGetDevCaps'
    Function group: 'Windows Multimedia'
    19 sec.Function: 'GetRegionData'
    Function group: 'Region'
    22 sec.Articles
    25 sec.Function: 'GetVersion'
    Function group: 'System Information'
    28 sec.
    Function group: 'Authentication'
    31 sec.Function: 'SHGetFileInfo'
    Function group: 'Shell Functions'
    Google
    Advertise here!