VBA code for custom ribbon tool errors in Excel 2016 -


the code follows works in excel 2013 , prior, upon installing excel 2016 (via office 365 subscription) , opening 1 of workbooks custom ribbon tools, "can't find library" error. ( there no missing references)

here 1 sample sub (dropdown control in ribbon) error pops up. error on call, doesn't returnedval.

'callback rxdrdnacctname onaction sub rxdrdnacctname_click(control iribboncontrol, id string, index integer)     on error resume next     call rxdropdownitemlabel(control, index, returnedval)          sheets("tables").range("acctnametoplot").value = returnedval     if err.number <> 0         logerror(now & "...ribbontool--> " & err.description)     end if end sub 

here code sub getting called

'callback rxdrdnacctname getitemlabel sub rxdropdownitemlabel(control iribboncontrol, index integer, byref returnedval)     dim varitems variant     if (control.id = "rxdrdnacctname" or control.id = "rxdrdnnewacctname")         varitems = thisworkbook.sheets("tables").range("sortedacctlist").value     elseif (control.id = "rxdrdnyear" or control.id = "rxdrdnnewacctyear")         varitems = thisworkbook.sheets("tables").range("yearslist").value     elseif control.id = "rxdrdnmonth"         varitems = thisworkbook.sheets("tables").range("monthnames").value     elseif control.id = "rxdrdncommod"         varitems = thisworkbook.sheets("tables").range("commodityplnameslist").value     elseif control.id = "rxdrdnsheetselectname"         varitems = thisworkbook.sheets("tables").range("allsheetsnames").value     end if     returnedval = varitems(index + 1, 1) end sub 

what has changed in excel 2016 (for customizing ribbon) has broken code?


Comments

Popular posts from this blog

Spring Boot + JPA + Hibernate: Unable to locate persister -

go - Golang: panic: runtime error: invalid memory address or nil pointer dereference using bufio.Scanner -

c - double free or corruption (fasttop) -