Hi,

I have a problem with context menu.....
I have a context menu of copy past action handler on QTableWidget.

Qt Code:
  1. QAction* copyAct = new QAction("&Copy", qTableWidgetObj);
  2. copyAct->setShortcut(tr("Ctrl+C"));
To copy to clipboard, switch view to plain text mode 

and for paste:
Qt Code:
  1. QAction* pasteAct = new QAction("&Paste", qTableWidgetObj);
  2. pasteAct->setShortcut(QKeySequence::Paste);
To copy to clipboard, switch view to plain text mode 

I connect this with a slot as

Qt Code:
  1. connect(copyAct, SIGNAL(triggered()), this, SLOT(slotCopy()));
To copy to clipboard, switch view to plain text mode 

I create context menu with

Qt Code:
  1. qTableWidgetObj->setContextMenuPolicy(Qt::ActionsContextMenu);
To copy to clipboard, switch view to plain text mode 

Contextmenu gets creates and works fine if I press on one of the options of context menu.
But when I press shortcut key on the table widget no slot is called.

Please let me know your suggestions as how to implement it?