Hi Taco,
I followed your script for this and found that importing and exploding the text from the DWG puts the text in an order in my list as i grab them with Dynamo. If you place Rooms by points (X,Y from the imported text) with Dynamo, those Rooms have the same order in the Room list, so index 1 from your text list is the same as the index 1 of the Rooms that are placed. Therefore matching the lists by index will work also to put the Room numbers in. You can always check this by putting in a Furniture family in between and writing the text to that by matching the coordinates and adding an Element.Room node.
When importing just the Roomnumbers you will get a single item per Room, and i believe this is consistent with what Jeremy Tamnik says about assigning Id’s to newly created elements, the indexes in Dynamo’s lists will match.
All this works when starting with a new non-workshared revit file.
The rest of the Room properties can then be matched with an excel sheet, if you have one
Then copy the Rooms to your projectfile.
Marcel
Edit:
Added the scripts.
Remember to use a new revit project without a template
1_create room at textnote XYZ for roomnumber.dyn (8.7 KB)
2_set number to room.dyn (4.6 KB)
3_bimorphNodes.CurvesFromCADLayers and make curves into RoomSeparators.dyn (22.2 KB)