Share via

=SpellNumber

Anonymous
2019-05-01T17:03:27+00:00

I  have followed the directions on how to make and use the =SpellNumber function.  When I put it in my workbook I get back #NAME?

How do I remedy this?

Microsoft 365 and Office | Excel | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

HansV 462.6K Reputation points
2019-05-01T22:01:15+00:00

Thanks!

  1. You have the code for the SpellNumber function in more than one module. This confuses Excel.
  2. Some of the versions contain syntax errors.
  3. The formula should simply be =SpellNumber(…)

I have uploaded a working version to DropBox:

https://www.dropbox.com/s/pgx1k7km0j5yn34/Paystubs%20with%20spelling-no%20names.xlsm?dl=1

Was this answer helpful?

2 people found this answer helpful.
0 comments No comments

Answer accepted by question author

HansV 462.6K Reputation points
2019-05-02T09:01:49+00:00

You can open both workbooks: the one that already has the code, and the other one/

Then activate the Visual Basic Editor.

Drag the module from the workbook with the code to the other one and drop it. This will copy the module, making the SpellNumber function available in that workbook too.

If you want to be able to use the function in ALL workbooks, you can copy the module to your personal macro workbook Personal.xlsb.

You can then use the function as follows:

=Personal.xlsb!SpellNumber(A2)

See the following for info on Personal.xlsb:

https://support.office.com/en-gb/article/copy-your-macros-to-a-personal-macro-workbook-aa439b90-f836-4381-97f0-6e4c3f5ee566

https://www.rondebruin.nl/win/personal.htm

Was this answer helpful?

1 person found this answer helpful.
0 comments No comments

10 additional answers

Sort by: Most helpful
  1. Anonymous
    2019-05-02T14:29:12+00:00

    Thank you so much for your help!

    Was this answer helpful?

    1 person found this answer helpful.
    0 comments No comments
  2. Anonymous
    2019-05-01T19:53:57+00:00

    I did copy it and pasted it into Insert> Module.

    Was this answer helpful?

    0 comments No comments
  3. HansV 462.6K Reputation points
    2019-05-01T19:06:10+00:00

    You should copy the code for the SpellNumber function into a standard module - the type that you create by selecting Insert > Module in the Visual Basic Editor.

    It won't work if you copy the code into ThisWorkbook or into a worksheet module.

    Was this answer helpful?

    0 comments No comments