Using Win32 functions in Visual FoxPro Image Gallery
Printing and Print Spooler
..msdn
AddPort
AddPrinter
ClosePrinter
ConfigurePort
ConnectToPrinterDlg
DeletePort
DeviceCapabilities
DocumentProperties
EndDoc
EndPage
EnumForms
EnumJobs
EnumPorts
EnumPrinterData
EnumPrinterDrivers
EnumPrinters
EnumPrintProcessorDatatypes
EnumPrintProcessors
Escape
FindClosePrinterChangeNotification
FindFirstPrinterChangeNotification
FindNextPrinterChangeNotification
FreePrinterNotifyInfo
GetDefaultPrinter
GetPrinter
GetPrinterData
GetPrinterDriverDirectory
GetPrintProcessorDirectory
OpenPrinter
PrinterProperties
SetDefaultPrinter
SetJob
SetPrinter
StartDoc
StartPage
Code examples:
Enumerating ports that are available for printing on a specified server
DeletePort
..msdn    Add comment     W32 Constants      Translate this page
Displays a dialog box that allows the user to delete a port name.
Code examples:
Enumerating ports that are available for printing on a specified server
Declaration:
BOOL DeletePort(
    LPTSTR pName,      // server name
    HWND hWnd,         // handle to parent window
    LPTSTR pPortName   // port name
);
FoxPro declaration:
DECLARE INTEGER DeletePort IN winspool.drv;
    STRING  pName,;
    INTEGER hWindow,;
    STRING  pPortName

Parameters:
pName
[in] Pointer to a zero-terminated string that specifies the name of the server for which the port should be deleted. If this parameter is NULL, a local port is deleted.

hWnd
[in] Handle to the parent window of the port-deletion dialog box.

pPortName
[in] Pointer to a zero-terminated string that specifies the name of the port that should be deleted.
Return value:
If the function succeeds, the return value is a nonzero value.
My comment:
The DeletePort function returns an error if a printer is currently connected to the specified port.

The caller of the DeletePort function must have SERVER_ACCESS_ADMINISTER access to the server to which the port is connected.

See also: AddPort, EnumPorts.
Word Index links for the DeletePort :
Translate this page:
  Spanish    Portuguese    German    French    Italian  
FreeTranslation.com offers instant, free translations of text or web pages.
Created: 2005-09-22 12:36:13
Modified: 2005-12-19 17:02:38
Visited in last 7 days: 16
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.197.86)
13 sec.Function: 'GdipCloneBitmapArea'
25 sec.Function: 'GetCharABCWidths'
39 sec.Function: 'DefWindowProc'
52 sec.Function: 'IsChild'
1.1 min.Function: 'GetMenuBarInfo'
1.32 min.Function: 'CryptGenRandom'
Function group: 'Cryptography Reference'
1.58 min.
Function group: 'Power Management'
1.83 min.Function: 'RegSetValueEx'
2.05 min.Function: 'SetProcessPreferredUILanguages'
2.3 min.Function: 'SwitchToThisWindow'
Google
Advertise here!