?
Solved

Get selected item in inbox

Posted on 2003-02-26
12
Medium Priority
?
296 Views
Last Modified: 2013-12-18
hi guys,
first of all im new to notes programming, so please be patient...
here is my problem:
i need a function, that returns me the mailitem a user selects(not opens) in his/her inbox...
i want to add a button(i think its called agent in notes) in the inbox view and when somebody first selects a mail, then clicks on the button i want to work with the selected message (e.g. resend it to another address)...
is this possible? (i hope anyone understands what i am talking about)
i would be glad if someone answers...
0
Comment
Question by:beku
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 6
12 Comments
 
LVL 9

Expert Comment

by:Arunkumar
ID: 8025368
Just use the Forward button and this email will be copied to a new memo and you can edit it before sending it to someone !!!

-Arun.
0
 
LVL 9

Expert Comment

by:Arunkumar
ID: 8025371
You are lucky as you can select multiple mails and use Forward all the memos will be copied into a new mail.
0
 
LVL 9

Expert Comment

by:Arunkumar
ID: 8025426
And...if you dont see the forward button already on the view you can find it in the Actions menu.
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 

Author Comment

by:beku
ID: 8025635
First of all thx for your Xtremly fast reply Arun...
but think you didnt understand my question(this is not a question about handling the notes client, its about customizing the mail6 template with domino designer). i will try to explain the WHOLE problematic:
first of all i want to add a button to the mail6 template.
this button should be seen by any user, that looks into his/her inbox. i will place the button next to the "forward" and "reply" buttons. i will name it "voice".
now, if some user selects a voicemail in his/her inbox and then clicks on my custom voice button, i would like to read his/her phone number from the address book and then forward the mail to his/her telephone (i have written a mailserver application that can do this).

i know how to do all of this, except how to get the selected mail object(the mailmessage the user selects, before he/she clicks on my custom voice button), so i can change the "To" address and forward it via my mailserver application to the telephone... (maybe this inbox view has some property that can return me the selected message)

ps.: sorry for my bad expression (i dont speak native english)
0
 
LVL 9

Expert Comment

by:Arunkumar
ID: 8025716
oh okay...

Hopeyou have designer client with you.  On the server locate the StdR60Mail Template.

Open the database (A Template has .ntf extension) and on the left pane find the design elements.  Locate Folder and inside folders you will see ($InBox).  Double click to open this in designer client.  You will see the programmers pane at the bottom and the view design at the top.  Select from view menu - View - Action Bar.

This will open a new pane where you can see the buttons. Now this is the place you can add a new action button to your template.  Create - Action from the menu will allow you to do it.

Once you do it in the template it will be propagated to all the mailboxes overnight. You could also custom force design immediately by issuing console command.

Overall...touching the design of the template is risky. Make a backup before you start playing.

-Arun.
0
 

Author Comment

by:beku
ID: 8025956
...adding the button to the template is not the problem, i also know how to "distribute" the template to all the clients with the "load design" console command.

the problem is how to automatically insert the "office phone number" of the address book entry into the "To" field of the message(the one the user selects before he/she presses the "voice" button i added) and then automatically forward it...

i know how to get the "office phone number" of the current user from the address book via lotus script(i wrote a small function that retrieves the "office phone number" of the current user).

but i dont know how to !automatically! alter the "To" field of the selected message and then send it (with attachments).
0
 
LVL 9

Accepted Solution

by:
Arunkumar earned 300 total points
ID: 8026196
Here is a raw code untested....

------------
Dim ss As New notessession
     Dim ws As New NotesUIWorkSpace
     Dim uidoc As NotesUIDocument
     Dim db As  NotesDatabase
     Set db = ss.Currentdatabase
     Dim dc As NotesDocumentCollection
     Dim doc As NotesDocument
     Dim rt As notesrichtextitem    
     Set dc = db.UnProcessedDocuments
     
     If dc.Count <> 1 Then
          Msgbox "Please select only one document to forward"
     Else
          Set doc = dc.GetFirstDocument          
          Set rt = doc.GetFirstItem("Body")
         
          Dim newdoc As NotesDocument
          Dim rt1 As NotesRichTextItem          
          Set newdoc = db.CreateDocument
          newdoc.Form = "Memo"
          Set rt1 = New NotesRichTextItem(newdoc, "Body")
          Call rt.AppendRTItem(rt1)
          newdoc.SendTo = "TESTING"          ' Change this TESTING to have your phone number.
          Set uidoc = ws.EditDocument(newdoc)              
     End If              
----------------------
0
 

Author Comment

by:beku
ID: 8026242
ahhh i see!
seems like you are the real god of domino designer!
thx very much for your patience!
its a pity i only have 75 points... if i had more i would give them to u! you really deserve them!
adios!
0
 
LVL 9

Expert Comment

by:Arunkumar
ID: 8026261
Did it work for you ?
0
 

Author Comment

by:beku
ID: 8026837
i will test it tomorrow since i have too much to do today..
if it doesent work, i will write another comment...
0
 

Author Comment

by:beku
ID: 8033082
hi arun,
im afraid, it didnt work...
the new form opens, but the sendto field is not replaced.
i tried to debug the script, and in the sendto property of the new document , the sendto field is filled with my phone number. strange isnt it?
another problem is, that the new form that opens, has no send button. even though i specified the form type as memo, it has the same buttons as the inbox...
i would also like the new memo to send itself automatically after the sendto field is filled in...
0
 

Author Comment

by:beku
ID: 8034223
finally solved the problem:
Dim ss As New notessession
    Dim ws As New NotesUIWorkSpace
    Dim uidoc As NotesUIDocument
    Dim db As  NotesDatabase
    Set db = ss.Currentdatabase
    Dim dc As NotesDocumentCollection
    Dim doc As NotesDocument
    Dim rt As notesrichtextitem    
    Set dc = db.UnProcessedDocuments
   
    If dc.Count <> 1 Then
    Msgbox "Please select only one document to forward"
    Else
         Set doc = dc.GetFirstDocument          
         Set rt = doc.GetFirstItem("Body")
         
         Dim newdoc As NotesDocument
         Dim rt1 As NotesRichTextItem          
         Set newdoc = db.CreateDocument
         newdoc.Form = "Memo"
         Set rt1 = New NotesRichTextItem(newdoc, "Body")
         Call rt.AppendRTItem(rt1)
         newdoc.SendTo = "TESTING"'Change this TESTING    
         to have your phone number.
         Set uidoc = ws.EditDocument(newdoc)              
         uidoc.EditMode = True
         Call uidoc.FieldSetText("EnterSendTo", "TESTING")
     Calluidoc.Send                                             Call uidoc.Close
    End If              

0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

For users on the Lotus Notes 8 Standard client, this article provides information on checking the Java Heap size and adjusting it to half of your system RAM in attempt to get the Lotus Notes 8.x Standard client to run faster.  I've had to exercise t…
This article covers general Notes 8.5 troubleshooting information including recreating the Notes\Data folder.
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …
In this video, Percona Solutions Engineer Barrett Chambers discusses some of the basic syntax differences between MySQL and MongoDB. To learn more check out our webinar on MongoDB administration for MySQL DBA: https://www.percona.com/resources/we…
Suggested Courses

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question