PC SOFT

WINDEV的在线文档

  • Variables
文档页面当前正在翻译。对于此延迟我们深表歉意。
您可以自愿地帮助我们翻译您想要的文档段落,然后只需通过以下地址与我们联系:info@cn.windev.com
产品
WinDevWebDev-服务器代码WebDev-浏览器代码WinDev Mobile报表和查询
平台
WindowsLinuxWindows MobileWindows PhoneWindows Store appsAndroidAndroid Widget iPhone/iPad
语言
JavaPHPAjax用户代码(MCU)外部语言
数据库
HFSQLHFSQL Client/Server存储过程HF 5.5OLE DBODBC本地访问

Indicates the type of data and the data to copy/move during Drag/Drop.

Notes:

  • 鼠标拖放数据类型 must be used during the call to the 鼠标拖放.开始拖动 event (鼠标拖放事件).
  • 鼠标拖放数据类型 can be used several times with different formats to copy different types of data from the source.
例子
// Procedure called by the dndBeginDrag event
过程BeginDrag()
// The value of the source control ("EDT_Edit") is copied/moved
// This data is a character string
鼠标拖放数据类型鼠标拖放.TEXTEDT_Edit..值)

// Procedure called in the code for Beginning of Drag/Drop
// to perform a Drag and Drop
// to the file explorer or to another application
过程DNDToExplorersListFilePaths

// Windows structure used to manage
// Drag/Drop with the explorer
定义POINT结构型
xy整数型
结束

定义DROPFILES结构型
// Pointer to the list of files
pFiles整数型
// Source position of the mouse
PTPOINT型
// Reserved
fNC布尔型
// True if the list of files is in UNICODE, False otherwise
fWide布尔型
结束

// Fills a HDROP structure
stDROPFILESDROPFILES型
stDROPFILES:fWide
stDROPFILES:fNC
stDROPFILES:PT:x0
stDROPFILES:PT:y0
stDROPFILES:pFiles维度stDROPFILES

// sListFilePaths contains the list of files separated by CR characters
// for the multi-files, the CR character is replaced by a binary zero,
// and the 2 ending binary zeros are added
bufListOfFiles缓冲区型
如果变量类型sListFilePaths)=WL.Unicode字符串型,那么
bufListOfFiles替换sListFilePaths回车,...
Unicode值0))+Unicode值0)+Unicode值0
stDROPFILES:fWide
否则
bufListOfFiles替换sListFilePaths回车,...
字符0))+字符0)+字符0
stDROPFILES:fWide
结束

// 传递 the content of the structure into the buffer
// Calculate the necessary total size:
// size of the structure and size of file names
// with the 2 ending Unicode binary zeros
nSize整数型
nSize维度stDROPFILES)+长度bufListOfFiles

// Allocates a buffer for the DROP information
// to the requested size with binary zeros
bufDropData缓冲区型
bufDropDataRepeat字符0),nSize
// Includes the information of the stDROPFILES structure in the buffer
传递(&bufDropData,&stDROPFILES维度stDROPFILES))
// After the buffer, includes the names of the files
传递(&bufDropData+维度stDROPFILES),...
&bufListOfFiles长度bufListOfFiles))

// Indicates that it is a file DROP
鼠标拖放数据类型鼠标拖放.HDROP,&bufDropDatanSize

语法

Drag and Drop between WinDev applications 隐藏详细信息

鼠标拖放数据类型(<Type of Data> , <Data> [, <Size>])
<Type of Data>: Integer or character string
Type of data copied/moved.

  • Preset data types:
    Only some types of data are presented below. See the Microsoft documentation ("Standard Clipboard Formats") for more details.
鼠标拖放.TEXT1ANSI string ending with a \0 character
鼠标拖放.BMP2.BMP (bitmap image)
鼠标拖放.WMF3.WMF (graphic primitive file)
鼠标拖放.SYLK4.SLK, Excel, Multiplan
鼠标拖放.DIF5Data interchange format (lotus)
鼠标拖放.TIF6.TIF (TIFF image)
鼠标拖放.OEM7OEM string ending with a \0 character
鼠标拖放.DIB8.DIB (bitmap independent from the device managers)
鼠标拖放.PALETTE9Palette (Windows standard)
鼠标拖放.PENDATA10Optical pen
鼠标拖放.RIFF11Audio format
鼠标拖放.WAF12.WAV (sound data)
鼠标拖放.UNICODETEXT13Text string with characters coded on 2 bytes (support for internationalization)
鼠标拖放.EMF14.EMF (Windows 32-bit graphic primitives )
鼠标拖放.HDROP15Format of "dropped" file (in Windows NT)
鼠标拖放.LOCALE16Format local to Windows (in Windows NT)

  • Character string:
    Type of data created beforehand.
    For example:
    Data1 is string = CUSTOMER.KEY + TAB + INVOICE.PRICE
    DnDCacheData("MyType", Data1)

    The "MyType" type will correspond to what was assigned to the "Data" string.
<Data>: Character string
Data to retrieve.
<Size>: Optional integer
Number of bytes that will be assigned to <Data>.

Drag and Drop between a WinDev application and a Windows application 隐藏详细信息

鼠标拖放数据类型(<Type of Data> , <Pointer> [, <Size>])
<Type of Data>: Integer or character string
Type of data copied/moved.

  • Preset data types:
    Only some types of data are presented below. See the Microsoft documentation ("Standard Clipboard Formats") for more details.
鼠标拖放.TEXT1ANSI string ending with a \0 character
鼠标拖放.BMP2.BMP (bitmap image)
鼠标拖放.WMF3.WMF (graphic primitive file)
鼠标拖放.SYLK4.SLK, Excel, Multiplan
鼠标拖放.DIF5Data interchange format (lotus)
鼠标拖放.TIF6.TIF (TIFF image)
鼠标拖放.OEM7OEM string ending with a \0 character
鼠标拖放.DIB8.DIB (bitmap independent from the device managers)
鼠标拖放.PALETTE9Palette (Windows standard)
鼠标拖放.PENDATA10Optical pen
鼠标拖放.RIFF11Audio format
鼠标拖放.WAF12.WAV (sound data)
鼠标拖放.UNICODETEXT13Text string with characters coded on 2 bytes (support for internationalization)
鼠标拖放.EMF14.EMF (Windows 32-bit graphic primitives )
鼠标拖放.HDROP15Format of "dropped" file (in Windows NT)
鼠标拖放.LOCALE16Format local to Windows (in Windows NT)

  • Character string:
    Type of data created beforehand.
    For example:
    Data1 is string = CUSTOMER.KEY + TAB + INVOICE.PRICE
    DnDCacheData("MyType", Data1)

    The "MyType" type will correspond to what was assigned to the "Data" string.
<Pointer>: Integer
Pointer to a character string, a structure, ...
<Size>: Optional integer
Number of bytes that will be assigned to <Pointer>.

注意

Variables

The following variables can be used:
Name of the variableDescription
鼠标拖放.操作Action specified in 鼠标拖放接受.

The possible values are as follows: 鼠标拖放.复制, 鼠标拖放.移动 and 鼠标拖放.禁止.

This variable is not filled at the beginning of Drag and Drop in a source control (鼠标拖放.开始拖动 constant) or when exiting from a target control (鼠标拖放.离开控件 constant).
鼠标拖放.目标控件Name of the target control.

This variable is not filled at the beginning of Drag and Drop in a source control (鼠标拖放.开始拖动 constant) or when exiting from a target control (鼠标拖放.离开控件 constant).
鼠标拖放.源控件Name of the source control.
鼠标拖放.按下CtrlStatus of the [Ctrl] key:
  • : the [Ctrl] key is pressed.
  • : the [Ctrl] key is not pressed.
This variable is not filled at the beginning of Drag and Drop in a source control (鼠标拖放.开始拖动 constant) or when exiting from a target control (鼠标拖放.离开控件 constant).
鼠标拖放.源窗口Name of the source window.

This variable is not filled when exiting from a target control (鼠标拖放.离开控件 constant).
鼠标拖放.鼠标水平位置Horizontal position (X) of the mouse cursor in relation to the control handled during the event.

This variable is not filled when exiting from a target control (鼠标拖放.离开控件 constant).
鼠标拖放.鼠标垂直坐标Vertical position (Y) of the mouse cursor in relation to the control handled during the event.

This variable is not filled when exiting from a target control (鼠标拖放.离开控件 constant).

The 鼠标拖放.源控件 and 鼠标拖放.源窗口 variables return an empty string ("") when the Drag and Drop comes from an application other than the current application.

组件
WinDev wd200obj.dll