Warning: Illegal string offset 'status' in /home2/icentarb/public_html/icentar/print.php on line 190

Warning: Illegal string offset 'status' in /home2/icentarb/public_html/icentar/print.php on line 190
iCentar » Racunari i oprema » Programirannje i baze podataka » Access » Acces2010 i skočni meni
miro35 11.11.2013 09:26
Predmet:Acces2010 i skočni meni

Već radim sa access 2010 i programiram vlastite ribone itd..
Zna li neko kako napraviti skočni meni u access2010. Znači desni klik na nekoj formi i da se pojavi pop up meni za izbor neke komande.
Znam dobro kako se pravi u access2003.

zxz 11.11.2013 17:31
Predmet:Re: Acces2010 i skočni meni

Ja ne nadjoh mada na svom compu i nemam access 2010.
Jedino se moze napraviti u nizoj verziji napr. 2003 te impotovati u vecu verziju.
Tp sam probao i radi kako vaja pa ako hoces mogu malo bolje objasniti.

roko 11.11.2013 21:28
Predmet:Re: Acces2010 i skočni meni

ovo san radio pred godinu dve. mislim da ti u kodu ima više nego što ti treba.
kod ti ide na In love
Form_Load()
CreateShortcutMenuWithGroups ("LP")
ShortcutMenuBar = "cmdFormFiltering"

tu ima i nekih kombinacija i na reportu pa malo istraži
poz
Prilozi:
RClick.rar (Velicina datoteke:2.41 KB)

miro35 12.11.2013 11:18
Predmet:Re: Acces2010 i skočni meni

hvala ti evo gledam malo,na tragu sam rješenja.

miro35 12.11.2013 12:56
Predmet:Re: Acces2010 i skočni meni

Evo našao sam i ovo možda nekom zatreba za Shortcat menu u access 2010.
Ovo ubaciti u neki modul:
PreuzmiIzvorni kôd (Text):
  1. Sub CreateContextMenu()
  2.     Dim cbr As CommandBar
  3.     Dim cbb As CommandBarButton
  4.     ' Delete the command bar if it already exists
  5.     DeleteContextMenu
  6.     ' Create a new command bar of type msoBarPopup
  7.     Set cbr = CommandBars.Add(Name:="MyBar", Position:=msoBarPopup)
  8.     With cbr
  9.         ' Add first item
  10.         Set cbb = .Controls.Add(type:=msoControlButton)
  11.         With cbb
  12.             .Caption = "Item 1"
  13.             .Style = msoButtonCaption
  14.             .OnAction = "MyFunc1"
  15.         End With
  16.         ' Add second item
  17.         Set cbb = .Controls.Add(type:=msoControlButton)
  18.         With cbb
  19.             .Caption = "Item 2"
  20.             .Style = msoButtonCaption
  21.             .OnAction = "MyFunc2"
  22.         End With
  23.         ' Add third item
  24.         Set cbb = .Controls.Add(type:=msoControlButton)
  25.         With cbb
  26.             .Caption = "Item 3"
  27.             .Style = msoButtonCaption
  28.             .OnAction = "MyFunc3"
  29.         End With
  30.         ' Add fourth item
  31.         Set cbb = .Controls.Add(type:=msoControlButton)
  32.         With cbb
  33.             .Caption = "Item 4"
  34.             .Style = msoButtonCaption
  35.             .OnAction = "MyFunc4"
  36.         End With
  37.     End With
  38. End Sub
  39.  
  40. ' Delete the shortcut menu
  41.  
  42. Sub DeleteContextMenu()
  43.     On Error Resume Next
  44.     CommandBars("MyBar").Delete
  45. End Sub
  46.  
  47. ' These functions are executed by the shortcut menu items
  48.  
  49. Function MyFunc1()
  50.     MsgBox "This is MyFunc1", vbInformation
  51. End Function
  52.  
  53. Function MyFunc2()
  54.     MsgBox "This is MyFunc2", vbInformation
  55. End Function
  56.  
  57. Function MyFunc3()
  58.     MsgBox "This is MyFunc3", vbInformation
  59. End Function
  60.  
  61. Function MyFunc4()
  62.     MsgBox "This is MyFunc4", vbInformation
  63. End Function
Zatim izabrati na propertis forme Shortcat menu:MyBar