Export (0) Print
Expand All
COM
id
in
int
odl
out
ptr
ref
Expand Minimize
This topic has not yet been rated - Rate this topic

immediatebind attribute

The [immediatebind] attribute indicates that the database will be notified immediately of all changes to a property of a data-bound object.


[
    interface-attribute-list
] 
interface | dispinterface interface-name 
{
    [bindable, immediatebind[, optional-attribute-list]] returntype function-name(params)
}

Parameters

interface-attribute-list

Specifies a list of one or more attributes that apply to the interface as a whole.

interface-name

Specifies the name of the interface or dispinterface.

optional-attribute-list

Zero or more function attributes.

returntype

Specifies the return type of the function.

function-name

Specifies the name of the function in the IDL file.

params

Zero or more function parameters.

Remarks

The [immediatebind] attribute allows controls to differentiate between properties that need to notify the database of every change, and those that do not. For example, every change to a checkbox control should be sent to the underlying database immediately, even if the control has not lost the focus. However, for a listbox control, a change occurs whenever a different selection is highlighted. Notifying the database of a change before the control loses focus would be inefficient and unnecessary. The [immediatebind] attribute allows you to specify, by setting the ImmediateBind bit, individual properties on a form whose changes should be reported immediately.

Properties that have the [immediatebind] attribute must also have the [bindable] attribute.

Flags

FUNCFLAG_FIMMEDIATEBIND, VARFLAG_FIMMEDIATEBIND

Examples

[
    uuid(12345678-1234-1234-1234-123456789ABC)
] 
interface MyObject : IUnknown
{
    properties:
    methods:
        [id(1), propget, bindable, immediatebind] long Size(void);

        [id(1), propput, bindable, 
         immediatebind] HRESULT Size([in]long lSize);
}

See also

bindable
TYPEFLAGS
interface
dispinterface
ODL File Syntax
ODL File Example
Generating a Type Library With MIDL

 

 

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.