?
Solved

receive email with attachment using powerbuilder

Posted on 2011-03-20
2
Medium Priority
?
1,125 Views
Last Modified: 2013-12-26
Hello,
Using PowerBuilder 9, what is the way to receive outlook email with attachment and save attachment file is specific folder.. with code please!.

thanks.

0
Comment
Question by:Deyhim
[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
  • 2
2 Comments
 
LVL 1

Accepted Solution

by:
Deyhim earned 0 total points
ID: 35196334
Im using :

long n, c_row,ll_upper

mses = CREATE mailsession
if (mses.mailLogon ( 'profile', '', mailNewSession! )) = MailReturnSuccess! then
   mSes.mailGetMessages(true)
ll_upper= UpperBound(mSes.MessageID)

   FOR n = 1 to ll_upper
    mSes.mailReadMessage(mSes.MessageID[n], &
    msg[n], mailEntireMessage!,True)
 messagebox('here',msg[n].AttachmentFile[1].Pathname )

 
FileMove ( string(msg[n].AttachmentFile[1].Pathname), 'c:\' + string(msg[n].AttachmentFile[1].filename      ) )
 

NEXT
  mSes.MailLogoff()
END IF

DESTROY mSes



but the name of file is wrong by consider only first 6 character  





// Turn security warnings back on
If li_ret = 0 Then
        lole_osm.DisableSMAPIWarnings = False
        lole_osm.DisconnectObject()
Destroy lole_osm
End If


0
 
LVL 1

Author Comment

by:Deyhim
ID: 35196822
i found the problem but dont know what is the solution .. please help

problem is mailFileDescription filename length is always 12 as maximum value and pathname is 51 !!!

please help me..
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

In our object-oriented world the class is a minimal unit, a brick for constructing our applications. It is an abstraction and we know well how to use it. In well-designed software we are not usually interested in knowing how objects look in memory. …
Programmer's Notepad is, one of the best free text editing tools available, simply because the developers appear to have second-guessed every weird problem or issue a programmer is likely to run into. One of these problems is selecting and deleti…
THe viewer will learn how to use NetBeans IDE 8.0 for Windows to perform CRUD operations on a MySql database.
The viewer will learn how to use and create new code templates in NetBeans IDE 8.0 for Windows.

650 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