Hi,
I have a settings view where I have an Binary item, CAknBinaryPopupSettingItem with pop up options as On/Off.
i want the phone to vibrate for some time when the user selects On option from the settings. How can I do this?
I have checked the Vibrate API and also made the vibrate function, but I don't know where to put it.

This below code is from CppExamples of SDK
_LIT(KBinaryText1, "On");
_LIT(KBinaryText2, "Off");

My Settings LoadList() is as follows.
CAknBinaryPopupSettingItem* item10 = new (ELeave) CAknBinaryPopupSettingItem(10, iBinary);
CleanupStack::PushL(item10);
// The same resource id can be used for multiple binary setting pages.
item10->ConstructL(isNumberedStyle, 10, KName10, icons, R_BINARY_SETTING_PAGE, -1, 0, R_POPUP_SETTING_BINARY_TEXTS);

// Load texts dynamically.
texts = item10->EnumeratedTextArray();
texts->ResetAndDestroy();
// Text 1
text = KBinaryText1().AllocLC();
enumText = new (ELeave) CAknEnumeratedText(0, text);
CleanupStack::Pop(text);
CleanupStack::PushL(enumText);
texts->AppendL(enumText);
CleanupStack::Pop(enumText);
// Text 2
text = KBinaryText2().AllocLC();
enumText = new (ELeave) CAknEnumeratedText(1, text);
CleanupStack::Pop(text);
CleanupStack::PushL(enumText);
texts->AppendL(enumText);
CleanupStack::Pop(enumText);

// Sets the correct text visible
item10->LoadL();


void CDynamicSettingListAppView:oVibrateL( TInt aDuration )
{
CHWRMVibra* vibra = CHWRMVibra::NewLC();

if ( CHWRMVibra::EVibraModeON == vibra->VibraSettings() ) // get vibration setting in the user profile
{
vibra->StartVibraL( aDuration );
}
CleanupStack::PopAndDestroy( vibra );
}
Now where should i use DoVibrate() function so that it vibrates when user choses On option