The renumbering is exactly what you need VBA for.
Please see the VBA help for the events exposed by the Items object. Use the
ItemAdd, ItemChange and ItemRemove events; whenever one of the events fire,
loop through all of the items and change the value of your custom property.
The property is available via the UserProperties collection.
For sure easier would be an apporach like this: Don't assign numbers like
1,2,3 etc. but, say, 1000, 2000, 3000. Now, if you want to insert a task at
the second position, give it 1500, the next second task could get 1250 etc.
This way, you have a lot space to insert tasks without that you have to
renumber anything.
--
Best regards
Michael Bauer - MVP Outlook
: Outlook Categories? Category Manager Is Your Tool
: VBOffice Reporter for Data Analysis & Reporting
: <http://www.vboffice.net/product.html?pub=6&lang=en>
Am Thu, 18 Jun 2009 14:59:13 -0700 schrieb sochoa:
> I went to tasks on outlook and did a right click on the to do list bar and
I
> was able to create a custom field where I can enter any number I want. The
> only thing that is missing is the ability for the tasks to automatically
> renumber themselves when tasks are added or deleted. Can anyone provide me
> with instructions on how to do that?
>
> Michael, do you happen to know how i can write the solution with VBA. Im
> savy with computers but I need some instruction on how I would go about
doing
> this and just what exactly VBA is (Are we talking about visual basic?)
>
> "Michael Bauer [MVP - Outlook]" wrote:
>
>>
>>
>> This cannot be achieved simply by creating a field, maybe with a formular
>> assigned. Instead, you'd need to write a more complex solution with VBA.
>>
>> --
>> Best regards
>> Michael Bauer - MVP Outlook
>>
>> : Outlook Categories? Category Manager Is Your Tool
>> : VBOffice Reporter for Data Analysis & Reporting
>> : <http://www.vboffice.net/product.html?pub=6&lang=en>
>>
>>
>> Am Mon, 15 Jun 2009 16:21:09 -0700 schrieb sochoa:
>>
>>> Hello, I have been looking for a while in instructions on how to do this
>> and
>>> have come up short. Hopefully one of you outlook gurus out there can
help
>> me
>>> out.
>>>
>>> Essentially i am looking for a way to create a field in the outlook task
>>> sections that allows me to assign a number to a task so that I know the
>>> priority in which i need to get tasks done. I am also hoping that it can
>> be
>>> coded so that if I delete or add a task (say task #2) the tasks that are
>>> numbered higher or lower will automatically adjust (if i delete task #2,
>> task
>>> #3 will become #2 and so on. If I add task #2, the old task #2 will
become
>> #
>>> 3 and so on)
>>>
>>> Please help.
>>
|