Davers
Well-known Member
- Joined
- Sep 17, 2002
- Messages
- 1,165
Hi everyone. I am doing my usual importing of an outlook form to an Excel spreadsheet. This time though, I have about 31 elements I'd like to import. I am currently doing it like this:
Is there a way I can get a count of the elements in an outlook form, then loop through them all using some something like:
so I don't have to have 31 lines of code to import this stuff?? Let me know if I am being too vague, and I'll post all of my code, or explain in greater detail!
Thanks for any help and have a good day,
Dave
Code:
Cells(NextRow, 3) = MItem.UserProperties("039DealerName").Value
Cells(NextRow, 4) = MItem.UserProperties("039P&ACode").Value
Cells(NextRow, 5) = MItem.UserProperties("039PolarityChangeStatus").Value
Is there a way I can get a count of the elements in an outlook form, then loop through them all using some something like:
Code:
For Each Item In MItem
Cells(NextRow, MItemCount) = MItem.UserProperties(Item).Value
Next
so I don't have to have 31 lines of code to import this stuff?? Let me know if I am being too vague, and I'll post all of my code, or explain in greater detail!
Thanks for any help and have a good day,
Dave