Using Win32 functions in Visual FoxPro Image Gallery
Shell Lightweight Utility APIs -- string functions
..msdn
ChrCmpI
StrCpy
StrDup
wnsprintf
Code examples:
StrDup returns a pointer to the duplicate of a source VFP string
Using Common Controls: the Header Control
StrDup
..msdn    Add comment     W32 Constants      Translate this page
Duplicates a string.
Code examples:
Using Common Controls: the Header Control
StrDup returns a pointer to the duplicate of a source VFP string
Declaration:
LPTSTR StrDup( 
    LPCTSTR lpsz 
);
FoxPro declaration:
DECLARE INTEGER StrDup IN shlwapi;
    STRING lpsz
Parameters:
lpsz
[in] Pointer to a constant null-terminated character string.
Return value:
Returns the address of the string that was copied, or NULL if the string cannot be copied.
My comment:
MSDN: this function uses LocalAlloc to allocate storage space for the copy of the string. The calling application must free this memory by calling the LocalFree function on the pointer returned by the call to StrDup.

StrDup will allocate storage the size of the original string. If storage allocation is successful, the original string is copied to the duplicate string.
Translate this page:
  Spanish    Portuguese    German    French    Italian  
FreeTranslation.com offers instant, free translations of text or web pages.
Created: 2001-10-30 19:19:00
Modified: 2001-11-26 16:03:53
Visited in last 7 days: 21
User Contributed Notes:
There are no notes on this subject.


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.37), the Open Source standard SQL database, AceHTML Freeware Version 4, freeware HTML Editor of choice.   Hosted by Korax Online Inc.
Last Topics Visited (54.224.43.96)
18 sec.Function: 'StrToInt'
35 sec.Function: 'CommandLineToArgvW'
57 sec.Function: 'SHGetPathFromIDList'
1.25 min.
Function group: 'File System'
1.57 min.
Function group: 'Dialog Box'
1.9 min.Function: 'FtpCommand'
2.28 min.Function: 'FtpDeleteFile'
2.63 min.Function: 'GetCurrencyFormat'
3.02 min.Function: 'PathBuildRoot'
3.5 min.Function: 'GetPerformanceInfo'
Google
Advertise here!