![]() |
If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
![]()
I would like to ask someone experienced - I think I can use UserProperties
ang Property tags somehow intuitively but still there is something that inhibits me to imagine how to rename all the Custom fields "Name1" to "Name2". Firstly, I think it fill not be possible to change the name of the existing property and the only solution would be to find oMailItem.Fields(poprtag) and to delete it somehow and to create some with new name and copy the value, is it right ? My question is, the old property disappears from the folder completely including old Propertytag in the moment that I delete it from last items, is it right ? Or, it does never disappear ? Or, Is it good to create a new folder and then move all the "in-this-way-renamed" items to the new folder to get rid of the balast (old named fields)? And, what object would you recommend to use with Redemtion to "rename", even by the deleting- adding new - method. - for 6000 items to run fast enough ? Of course also Form has to be adapted to use new UserNames. thank you |
#2
|
|||
|
|||
![]()
You cannot change the name of a UserProperty once it's created. You'd have
to delete it and create a new property with the name you want. You also can't change a UserProperty data type once it's created. If the UserProperty was created only in the items then deleting it from all items with that property will completely remove it. If it was also added to the folder fields then deleting it from all items won't be enough to completely remove all traces of it. Can I ask why you need to do all this and not just leave things as they are? Whatever method you use will still involve getting each item in the folder and deleting the properties and creating new ones. I don't think Redemption would be significantly faster in that case than using the Outlook object model. Whatever you use will take time for 6000 items. -- Ken Slovak [MVP - Outlook] http://www.slovaktech.com Author: Professional Programming Outlook 2007. Reminder Manager, Extended Reminders, Attachment Options. http://www.slovaktech.com/products.htm "Bert_Bert" wrote in message ... I would like to ask someone experienced - I think I can use UserProperties ang Property tags somehow intuitively but still there is something that inhibits me to imagine how to rename all the Custom fields "Name1" to "Name2". Firstly, I think it fill not be possible to change the name of the existing property and the only solution would be to find oMailItem.Fields(poprtag) and to delete it somehow and to create some with new name and copy the value, is it right ? My question is, the old property disappears from the folder completely including old Propertytag in the moment that I delete it from last items, is it right ? Or, it does never disappear ? Or, Is it good to create a new folder and then move all the "in-this-way-renamed" items to the new folder to get rid of the balast (old named fields)? And, what object would you recommend to use with Redemtion to "rename", even by the deleting- adding new - method. - for 6000 items to run fast enough ? Of course also Form has to be adapted to use new UserNames. thank you |
#3
|
|||
|
|||
![]()
If the UserProperty was created only in the items then deleting it from all
items with that property will completely remove it. If it was also added to the folder fields then deleting it from all items won't be enough to completely remove all traces of it. Can I ask why you need to do all this and not just leave things as they are? Whatever method you use will still involve getting each item in the folder and deleting the properties and creating new ones. I don't think Redemption would be significantly faster in that case than using the Outlook object model. Whatever you use will take time for 6000 items. Well, I am designing Language vocabulary flexible storage that would examine you and store how successful you were back so that it examines you more often from words you did not know. Such a solution has advantage of synchronized personal knowledge that evolves during the time with you. The vocabulary and the schedules being in one folder. What I need to do is, As I designed this solution I hd less experience than now and I would like to do some meintenance of the sample vocabulary so that it looks nicer. Also, as I learned how to restrict with categores, I can remove my temp field Categ2 that enabled me to filter and was duplicate and had to be copied with the form so it was something I did not like at all. I mean, I need this to make "Maintenance admin form" for me only, not for the end user :-) I am creating this kind of solution in my free time and dedicated a lot alot of time so far and it works very quickly and I at least have some results with redemption tahnks to your advices. you can see a few screenshots at http://filip.laburda.cz/zkouseni/zkouseni.html the main advantage is, the store with vocabulary is very flexible to categorize and is always up-to date with person that learns language Do I understand it right, that with first item that exists in the store, the store is aware of this fact and blocks the field from being deleted until I remove the last item or, until I remove last occurence of the field, then also PropertyTag that is unique for the store/perhaps folder?? can be released ? It is still great mystery for me :-) |
#4
|
|||
|
|||
![]()
If a user property is added only to individual items then deleting it from
each item where it exists will completely remove it. If it was also added to the folder then even deleting every item in the folder won't remove it from the folder fields. That would have to be done using a different API such as Extended MAPI (C++ or Delhi only, no managed code) or CDO 1.21 or Redemption (www.dimastr.com/redemption) to get at the folder fields. -- Ken Slovak [MVP - Outlook] http://www.slovaktech.com Author: Professional Programming Outlook 2007. Reminder Manager, Extended Reminders, Attachment Options. http://www.slovaktech.com/products.htm "Bert_Bert" wrote in message ... If the UserProperty was created only in the items then deleting it from all items with that property will completely remove it. If it was also added to the folder fields then deleting it from all items won't be enough to completely remove all traces of it. Can I ask why you need to do all this and not just leave things as they are? Whatever method you use will still involve getting each item in the folder and deleting the properties and creating new ones. I don't think Redemption would be significantly faster in that case than using the Outlook object model. Whatever you use will take time for 6000 items. Well, I am designing Language vocabulary flexible storage that would examine you and store how successful you were back so that it examines you more often from words you did not know. Such a solution has advantage of synchronized personal knowledge that evolves during the time with you. The vocabulary and the schedules being in one folder. What I need to do is, As I designed this solution I hd less experience than now and I would like to do some meintenance of the sample vocabulary so that it looks nicer. Also, as I learned how to restrict with categores, I can remove my temp field Categ2 that enabled me to filter and was duplicate and had to be copied with the form so it was something I did not like at all. I mean, I need this to make "Maintenance admin form" for me only, not for the end user :-) I am creating this kind of solution in my free time and dedicated a lot alot of time so far and it works very quickly and I at least have some results with redemption tahnks to your advices. you can see a few screenshots at http://filip.laburda.cz/zkouseni/zkouseni.html the main advantage is, the store with vocabulary is very flexible to categorize and is always up-to date with person that learns language Do I understand it right, that with first item that exists in the store, the store is aware of this fact and blocks the field from being deleted until I remove the last item or, until I remove last occurence of the field, then also PropertyTag that is unique for the store/perhaps folder?? can be released ? It is still great mystery for me :-) |
#5
|
|||
|
|||
![]()
I had big trouble in making bulk Property change using Redemption, CDO and
Outlook object model. Firstly, CDO is quick and straightforwaard enough to create the bulk rename script quickly, BUT, does not support Unicode so it forgets every foreigh characters during the conversion. Secondly, the Outlook object model is terribly slow (does not matter, I could let him do it overnight) but, worse is, as it is working on items with customized form, memory grows, grows, grows, after several hundred of items it all crashes, wow! Interesting point, if I remove form prom folder, there is no memory leak, but the script stops working :-) because UserProperties is dependant on the form published in the folder. Third: Redemption, it is Unicode, wow, it is quick, wow, it does not leak memory, wow, but it does NOT work. :-) well as I declared Dim up as Redemption.UserProperty Set up=oMessage.UserProperties.Find(..., true) 'tried string, PropTag I get Count 0, empty collection in debugger. Strange behaviour however is, that when I first make Set up_existing=oMessage.UserProperties.Add("myexistin gpropertyname") then o la la I can see instead of adding the value of my EXISTING value. This way I finally made the bulk migration tool working somehow but withou proper examples on the internet it was two days of really hard work - why the objects are so non-intuitive ? |
#6
|
|||
|
|||
![]()
1. Instead of using the standard CDO property tags use the _W set of tags.
For example, for subject instead of using CdoPR_SUBJECT = (&H37001E) use CdoPR_SUBJECT_W = (&H37001F). 2. The Outlook object model will be slower. Crashes like that are usually because you did not release objects each pass through the loop or were trying to use dot operators. For example instead of using oMessage.UserProperties.Find() you should instantiate a UserProperties collection and then set the specific UserProperty. Each dot operator adds an internal object that isn't released until the procedure ends. If using .NET code you might have to use Marshal.ReleaseComObject() on each object to fully release it. The same memory manangement would also apply with unmanaged code and with CDO or Redemption code too. 3. Is oMessage an RDOMail object or what? It isn't an Outlook object is it? The Outlook object model is the most intuitive and most documented of the 3 choices. CDO and Redemption are more for advanced users and since Redemption is based on MAPI you really should have some knowledge of MAPI to make the best use of Redemption. -- Ken Slovak [MVP - Outlook] http://www.slovaktech.com Author: Professional Programming Outlook 2007. Reminder Manager, Extended Reminders, Attachment Options. http://www.slovaktech.com/products.htm "Bert_Bert" wrote in message ... I had big trouble in making bulk Property change using Redemption, CDO and Outlook object model. Firstly, CDO is quick and straightforwaard enough to create the bulk rename script quickly, BUT, does not support Unicode so it forgets every foreigh characters during the conversion. Secondly, the Outlook object model is terribly slow (does not matter, I could let him do it overnight) but, worse is, as it is working on items with customized form, memory grows, grows, grows, after several hundred of items it all crashes, wow! Interesting point, if I remove form prom folder, there is no memory leak, but the script stops working :-) because UserProperties is dependant on the form published in the folder. Third: Redemption, it is Unicode, wow, it is quick, wow, it does not leak memory, wow, but it does NOT work. :-) well as I declared Dim up as Redemption.UserProperty Set up=oMessage.UserProperties.Find(..., true) 'tried string, PropTag I get Count 0, empty collection in debugger. Strange behaviour however is, that when I first make Set up_existing=oMessage.UserProperties.Add("myexistin gpropertyname") then o la la I can see instead of adding the value of my EXISTING value. This way I finally made the bulk migration tool working somehow but withou proper examples on the internet it was two days of really hard work - why the objects are so non-intuitive ? |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
User Defined Field type property | PocketRocket | Outlook - Using Contacts | 1 | December 15th 07 12:43 AM |
Exporting a User-Defined Field | JoeC | Outlook - Using Forms | 2 | September 4th 07 01:38 PM |
User Defined Field Initial Value | Matt | Outlook and VBA | 1 | May 6th 06 06:54 AM |
How do I rename user defined field names? | Sue Mosher [MVP-Outlook] | Outlook - Using Contacts | 1 | January 19th 06 03:13 AM |
rename 'User Field 1' field ? | E-Double | Outlook - Installation | 1 | January 16th 06 03:38 PM |