Forum Discussion
fonctions personnalisées provoquent une erreur #NOM?
Bonjour, mes fonctions personnalisées provoquent une erreur #NOM? dans la cellule.
Mes fonctions donnent un résultat correct lors d'un appel depuis un SUB en VBA.
Mes fonctions n'apparaissent pas dans la liste des fonctions Excel, ni dans les suggestions (autocomplete) lors de la saisie.
J'ai essayé le paramétrage de sécurité, l'utilisation d'un alias par le gestionnaire de nom (exemple des fonctions LAMBDA).
Pas de rubrique "Personnalisées" dans la Boite de dialogue Fonctions accessible depuis la Feuille de calcul.
9 Replies
- PeterBartholomew1Silver ContributorIt is not a SUB that is needed. You need to declare the procedure with FUNCTION and return the result using the function name.
- JeangaCopper Contributorsorry if I'm not clear enough.
"I create a FUNCTION in VBA, I use it by its name in a cell, Excel reply #NAME?" (bis)
When I use it in a Sub it works, but of course I create a function.
I use VBA since 1998 in Word and Excel, even it was called with an other name.
I use to program Function, (with Application.Volatile method, I'm not a rookie).
I think I've got here a bad parameters meaning but I can't put the finger on.
Is there a way to have a MICROSOFT technicien online to verify, quickly, the way I can retrieve my complete Excel pleasure ?- PeterBartholomew1Silver ContributorSorry, I misread your original post where it mentioned the SUB. Is the problem with a specific function or can't you define UDFs at all?
- NikolinoDEGold Contributor
Maybe I'm not the most appropriate to give you a suggested solution, but ...
With your permission, if I can recommend you, explain your problem in detail. So you can get a solution proposal to your problem much faster.
At the same time, it is much easier for someone who wants to help to understand the subject.
A win-win situation for everyone.
It is also helpful to know the operating system and Excel version, as different approaches may be required depending on the Office version and OS.
Thank you for your understanding and patience
Nikolino
I know I don't know anything (Socrates)