In a new purchase order database of mine, I add new items via a custom userform. Can I use "current region" to update the name of the expanded range each time "enter" is clicked, or do I need another method?
In a new purchase order database of mine, I add new items via a custom userform. Can I use "current region" to update the name of the expanded range each time "enter" is clicked, or do I need another method?
Why do you need to do this? Is it used in later code?
You could use a Dynamic Named Range.
Hope that helps.
RoyUK
--------
For Excel Tips & Solutions, free examples and tutorials why not check out my web site
Free DataBaseForm example
Thanks. To tell the truth, I'm more curious than anything else. I've been learning to do a lot more with ranges, formulas, etc., in VBA, & I just wondered, if I can select the current region, (I can), how would I then name it?
something like this - you could also refer to a cell such as A1 in the range reference vs a name
![]()
Please Login or Register to view this content.
not a professional, just trying to assist.....
If you create a Dynamic Named Range then you would't need to kep repeating the code.
Thanks again. I've created a dynamic named range & that works great. Like I said, though, I don't know how to create a "name" in vba. If I have a range selected, is it just like selection.name = "insertnamehere", or what? Sometimes I'm amazed at the tricks I can do with so little knowledge. Lots of fun though.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks