Int getnotelength(), Int getnoteskeycount(), Bool getnoteskeys() – Adobe Dreamweaver API Reference CS5 User Manual
Page 33

28
DREAMWEAVER API REFERENCE
The Design Notes API
Last updated 8/27/2013
FileHandle noteHandle = OpenNotesFile("file:///c|/sites/avocado8/iwjs/welcome.html");
if(noteHandle > 0){
int valueLength = GetNoteLength( noteHandle, "comments");
char* valueBuffer = new char[valueLength + 1];
GetNote(noteHandle, "comments", valueBuffer, valueLength + 1);
printf("Comments: %s",valueBuffer);
CloseNotesFile(noteHandle);
}
int GetNoteLength()
Description
This function gets the length of the value that is associated with the specified key.
Arguments
FileHandle noteHandle, const char keyName[64]
•
The noteHandle argument is the file handle that the
OpenNotesFile()
function returns.
•
The keyName[64] argument is a string that contains the name of the key.
Returns
An integer that represents the length of the value.
Example
See “
int GetNotesKeyCount()
Description
This function gets the number of key/value pairs in the specified Design Notes file.
Arguments
FileHandle noteHandle
•
The noteHandle argument is the file handle that the
OpenNotesFile()
function returns.
Returns
An integer that represents the number of key/value pairs in the Design Notes file.
BOOL GetNotesKeys()
Description
This function gets a list of all the keys in a Design Notes file.
Arguments
FileHandle noteHandle, char* keyBufArray[64], int keyArrayMaxLen
•
The noteHandle argument is the file handle that
OpenNotesFile()
returns.