Advertisement

05.09.2008 at 12:54PM PDT, ID: 23390660
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

FTP files via email

Is it possible to automatically send files to an FTP site (IP address) through Lotus Notes?  If so, can you please explain.
Start your free trial to view this solution
Question Stats
Zone: Software
Question Asked By: smcfarla
Solution Provided By: mbonaci
Participating Experts: 4
Solution Grade: B
Views: 0
Translate:
Loading Advertisement...
05.09.2008 at 01:00PM PDT, ID: 21536002

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.09.2008 at 01:13PM PDT, ID: 21536095

Rank: Master

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.11.2008 at 07:32PM PDT, ID: 21544371

Rank: Sage

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.11.2008 at 07:35PM PDT, ID: 21544380

Rank: Sage

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.12.2008 at 06:38AM PDT, ID: 21546849

Rank: Guru

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
 
Loading Advertisement...
Microsoft
  • Internet Protocols
  • Applications
  • Development
  • OS
  • Hardware
  • Windows Security
Apple
  • Operating Systems
  • Hardware
  • Programming
  • Networking
  • Software
Internet
  • Search Engines
  • File Sharing
  • WebTrends / Stats
  • Spy / Ad Blockers
  • Web Browsers
  • New Net Users
  • Web Development
  • Chat / IM
  • Anti Spam
  • Web Servers
  • Anti-Virus
  • Email Clients
Gamers
  • Tips
  • Online / MMORPG
  • Puzzle
  • Emulators
  • Action / Adventure
  • Role Playing
  • Consoles
  • Game Programming
  • Strategy
  • Sports
  • Misc
  • Computer Games
Digital Living
  • Hardware
  • Automotive
  • New Net Users
  • New Users
  • Software
  • Digital Music
  • Gaming World
  • Home Security
  • Apple
  • Networking Hardware
Virus & Spyware
  • Vulnerabilities
  • IDS
  • Encryption
  • Anti-Virus
  • Operating Systems Security
  • Software Firewalls
  • WebApplications
  • Cell Phones
  • Operating Systems
  • Internet
  • Hardware Firewalls
Hardware
  • Displays / Monitors
  • Handhelds / PDAs
  • Components
  • Peripherals
  • Laptops/Notebooks
  • Servers
  • Misc
  • Apple
  • Embedded Hardware
  • Networking Hardware
  • Storage
  • Desktops
  • New Users
Software
  • System Utilities
  • Industry Specific
  • Network Management
  • Photos / Graphics
  • Page Layout
  • VMware
  • Misc
  • Web Development
  • OS
  • CYGWIN
  • Voice Recognition
  • Virtualization
  • Message Queue
  • Quality Assurance
  • Security
  • Firewalls
  • MultiMedia Applications
  • Development
  • Database
  • Office / Productivity
  • Business Management
  • OS/2 Apps
  • Server Software
  • Internet / Email
ITPro
  • OS
  • Storage
  • Encryption
  • Operating Systems Security
  • Apple Hardware
  • Laptops & Notebooks
  • Servers
  • Networking Hardware
  • Peripherals
  • Devices
  • Displays / Monitors
  • WebTrends / Stats
  • Search Engines
  • Firewalls
  • Web Computing
  • WebApplications
  • IDS
  • Vulnerabilities
  • Email Clients
  • File Sharing
  • Spy / Ad Blockers
  • Web Browsers
  • Web Servers
  • Networking
  • Anti-Virus
  • Consulting
  • Chat / IM
  • Anti Spam
Developer
  • Web Servers
  • Web Browsers
  • Game Programming
  • Dev Tools
  • Industry Specific
  • Office / Productivity
  • Database
  • CYGWIN
  • Web Development
  • Search Engines
  • File Sharing
  • WebTrends / Stats
  • Programming
  • Content Management
  • Application Servers
  • Protocols
Storage
  • Removable Backup Media
  • Storage Technology
  • Servers
  • Grid
  • Remote Access
  • Backup / Restore
  • Misc
  • Hard Drives
OS
  • Miscellaneous
  • Security
  • Development
  • Linux
  • VMware
  • MainFrame OS
  • Unix
  • Apple
  • OS / 2
  • AS / 400
  • BeOS
  • Microsoft
  • VMS / OpenVMS
Database
  • Oracle
  • Miscellaneous
  • MySQL
  • Software
  • Sybase
  • Contact Management
  • PostgreSQL
  • Data Manipulation
  • Clarion
  • InterSystems Cache
  • Siebel
  • MUMPS
  • OLAP
  • SQLBase
  • SAS
  • GIS & GPS
  • 4GL
  • Berkeley DB
  • DB2
  • Informix
  • Interbase / Firebird
  • FoxPro
  • Reporting
  • LDAP
  • Filemaker Pro
  • MS SQL Server
  • dBase
  • MS Access
Security
  • Misc
  • Web Browsers
  • Software Firewalls
  • Operating Systems Security
  • File Sharing
  • Spy / Ad Blockers
  • Vulnerabilities
  • WebApplications
  • IDS
  • Anti-Virus
  • Encryption
  • Anti Spam
  • Email Clients
  • VPN
  • Chat / IM
Programming
  • Editors IDEs
  • Installation
  • Handhelds / PDAs
  • Multimedia Programming
  • System / Kernel
  • Automation
  • Algorithms
  • Game
  • Signal Processing
  • Project Management
  • Open Source
  • Database
  • Misc
  • Languages
  • Processor Platforms
  • Theory
Web Development
  • Scripting
  • Blogs
  • Web Servers
  • Software
  • Search Engines
  • Web Graphics
  • Web Services
  • Images
  • Internet Marketing
  • Images and Photos
  • Components
  • Document Imaging
  • Web Languages/Standards
  • Illustration
  • WebApplications
  • Fonts
  • WebTrends / Stats
  • Authoring
  • Digital Camera Software
  • Miscellaneous
Networking
  • Protocols
  • Apple Networking
  • Network Management
  • Message Queue
  • Application Servers
  • Content Management
  • File Servers
  • Email Servers
  • Misc
  • Java Editors & IDEs
  • Wireless
  • Networking Hardware
  • Backup / Restore
  • System Utilities
  • ISPs & Hosting
  • Web Servers
  • Storage Technology
  • Removable Backup Media
  • Servers
  • Web Computing
  • Broadband
  • Grid
  • OS / 2
  • Novell Netware
  • Unix Networking
  • Windows Networking
  • Security
  • Telecommunications
  • Operating Systems
  • Linux Networking
Other
  • Lounge
  • Business Travel
  • Community Support
  • New Net Users
  • Philosophy / Religion
  • Math / Science
  • Miscellaneous
  • URLs
  • Expert Lounge
  • Politics
  • Puzzles / Riddles
  • Automotive
Community Support
  • Suggestions
  • New to EE
  • New Topics
  • CleanUp
  • Announcements
  • General
  • Feedback
  • Input
  • EE Bugs
 
05.09.2008 at 01:00PM PDT, ID: 21536002
check out this websites... may be helps to solve your problem

http://en.allexperts.com/q/Using-Lotus-Notes-1427/Automatic-send-mail-message.htm

 
05.09.2008 at 01:13PM PDT, ID: 21536095

Rank: Master

Yes, it is possible.

use java ftp classes in a java agent.
see
http://www.nsftools.com/tips/JavaFtp.htm

 
05.11.2008 at 07:32PM PDT, ID: 21544371

Rank: Sage

All you need is a command line FTP program ( windows includes one ) and to execute it via direct or batch file via Lotus Notes Execute function.


I hope this helps !
 
05.12.2008 at 06:38AM PDT, ID: 21546849

Rank: Guru

The code contains the single script library, NotesFTP, that demonstrates how to implement basic FTP functionality in your applications without "shelling" out to the OS. Using the methods and properties of the "NotesFTPSession" Class, you can perform the following actions in your client or server-based LotusScript modules against a remote FTP server (provided you have appropriate access):
 - Navigate, enumerate, create, remove, and rename directories
 - Upload, download, rename, and remove files.

 As the NotesFTPSession Class makes calls to the Win32 Internet function library (wininet.dll), this script library can only be used on the Win32 platform.
  For complete details on using this script library, refer to the "About Database" document in the sample database.

by Paul Ray
CLP Principal Application Developer, R4 & R5

Hope this helps,
mb¤
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
41:
42:
43:
44:
45:
46:
47:
48:
49:
50:
51:
52:
53:
54:
55:
56:
57:
58:
59:
60:
61:
62:
63:
64:
65:
66:
67:
68:
69:
70:
71:
72:
73:
74:
75:
76:
77:
78:
79:
80:
81:
82:
83:
84:
85:
86:
87:
88:
89:
90:
91:
92:
93:
94:
95:
96:
97:
98:
99:
100:
101:
102:
103:
104:
105:
106:
107:
108:
109:
110:
111:
112:
113:
114:
115:
116:
117:
118:
119:
120:
121:
122:
123:
124:
125:
126:
127:
128:
129:
130:
131:
132:
133:
134:
135:
136:
137:
138:
139:
140:
141:
142:
143:
144:
145:
146:
147:
148:
149:
150:
151:
152:
153:
154:
155:
156:
157:
158:
159:
160:
161:
162:
163:
164:
165:
166:
167:
168:
169:
170:
171:
172:
173:
174:
175:
176:
177:
178:
179:
180:
181:
182:
183:
184:
185:
186:
187:
188:
189:
190:
191:
192:
193:
194:
195:
196:
197:
198:
199:
200:
201:
202:
203:
204:
205:
206:
207:
208:
209:
210:
211:
212:
213:
214:
215:
216:
217:
218:
219:
220:
221:
222:
223:
224:
225:
226:
227:
228:
229:
230:
231:
232:
233:
234:
235:
236:
237:
238:
239:
240:
241:
242:
243:
244:
245:
246:
247:
'+++++++++++++++++++++++++++++++++++++++
' NotesFTP Script Library
'+++++++++++++++++++++++++++++++++++++++
 
' private Win32 constants used by the Class
Private Const MAX_PATH = 260
Private Const INTERNET_FLAG_RELOAD = &H80000000
Private Const FILE_ATTRIBUTE_NORMAL = &H80
Private Const INTERNET_OPEN_TYPE_PRECONFIG = 0
Private Const INTERNET_INVALID_PORT_NUMBER = 0
Private Const INTERNET_SERVICE_FTP = 1
 
' public constants that can be used as arguments to the methods in the Class
Const FTP_TRANSFER_TYPE_BINARY = &H2
Const FTP_TRANSFER_TYPE_ASCII = &H1
Const INTERNET_FLAG_PASSIVE = &H8000000
 
' Win32 API struct for extracting file info
Private Type WIN32_FIND_DATA
      dwFileAttributes As Long
      ftCreationTime As Currency
      ftLastAccessTime As Currency
      ftLastWriteTime As Currency
      nFileSizeHigh As Long
      nFileSizeLow As Long
      dwReserved0 As Long
      dwReserved1 As Long
      cFileName As String * MAX_PATH
      cAlternate As String * 14
End Type
 
' function declarations for Win32 Internet API
Declare Private Function FtpFindFirstFile Lib "wininet.dll" Alias "FtpFindFirstFileA" (Byval hFtpSession As Long, Byval lpszSearchFile As String, lpFindFileData As WIN32_FIND_DATA, Byval dwFlags As Long, Byval dwContent As Long) As Long
Declare Private Function FtpSetCurrentDirectory Lib "wininet.dll" Alias "FtpSetCurrentDirectoryA" (Byval hFtpSession As Long, Byval lpszDirectory As String) As Integer
Declare Private Function FtpGetCurrentDirectory Lib "wininet.dll" Alias "FtpGetCurrentDirectoryA" (Byval hFtpSession As Long, Byval lpszCurrentDirectory As String, lpdwCurrentDirectory As Long) As Integer
Declare Private Function FtpPutFile Lib "wininet.dll" Alias "FtpPutFileA" (Byval hFtpSession As Long, Byval lpszLocalFile As String, Byval lpszRemoteFile As String, Byval dwFlags As Long, Byval dwContext As Long) As Integer
Declare Private Function FtpGetFile Lib "wininet.dll" Alias "FtpGetFileA" (Byval hFtpSession As Long, Byval lpszRemoteFile As String, Byval lpszNewFile As String, Byval fFailIfExists As Integer, Byval dwFlagsAndAttributes As Long, Byval dwFlags As Long, Byval 
dwContext As Long) As Integer
Declare Private Function FtpDeleteFile Lib "wininet.dll" Alias "FtpDeleteFileA" (Byval hFtpSession As Long, Byval lpszFileName As String) As Integer
Declare Private Function FtpCreateDirectory Lib "wininet.dll" Alias "FtpCreateDirectoryA" (Byval hConnect As Long, Byval lpszDirectory As String) As Integer
Declare Private Function FtpRenameFile Lib "wininet.dll" Alias "FtpRenameFileA" (Byval hConnect As Long, Byval lpszExisting As String, Byval lpszNew As String) As Integer
Declare Private Function FtpRemoveDirectory Lib "wininet.dll" Alias "FtpRemoveDirectoryA" (Byval hConnect As Long, Byval lpszDirectory As String) As Integer
Declare Private Function apiInternetCloseHandle Lib "wininet.dll" Alias "InternetCloseHandle" (Byval hInet As Long) As Long
Declare Private Function InternetOpen Lib "wininet.dll" Alias "InternetOpenA" (Byval sAgent As String, Byval lAccessType As Long, Byval sProxyName As String, Byval sProxyBypass As String, Byval lFlags As Long) As Long
Declare Private Function InternetConnect Lib "wininet.dll" Alias "InternetConnectA" (Byval hInternetSession As Long, Byval sServerName As String, Byval nServerPort As Integer, Byval sUsername As String, Byval sPassword As String, Byval lService As Long, Byval 
lFlags As Long, Byval lContext As Long) As Long
Declare Private Function InternetFindNextFile Lib "wininet.dll" Alias "InternetFindNextFileA" (Byval hFind As Long, lpvFindData As WIN32_FIND_DATA) As Long
 
' custom constants for errors raised by methods in the Class
Const NOTESFTP_INIT_FAILED = 300
Const NOTESFTP_DELETE_FAILED = 301
Const NOTESFTP_CONNECT_FAILED = 302
Const NOTESFTP_GETDIR_FAILED = 303
Const NOTESFTP_SETDIR_FAILED = 304
Const NOTESFTP_CREATEDIR_FAILED = 305
Const NOTESFTP_DELETEDIR_FAILED = 306
Const NOTESFTP_PUTFILE_FAILED = 307
Const NOTESFTP_GETFILE_FAILED = 308
Const NOTESFTP_RENAMEFILE_FAILED = 309
Const NOTESFTP_DELETEFILE_FAILED = 310
 
' our custom Class for instantiating NotesFTPSession objects
Class NotesFTPSession
 
	' private member variables used internally by the methods and properties within the Class
	Private hLib As Long
	Private hConnection As Long
 
	' constructor for NotesFTPSession Class...called when object is instantiated with "New" statement
	Sub New
		' initialize member vars
		Me.hLib=0
		Me.hConnection = 0
 
		' initialize data structures for subsequent calls to Win32 Internet functions
		Me.hLib = InternetOpen("Lotus Notes", INTERNET_OPEN_TYPE_PRECONFIG, Chr(0), Chr(0), 0)
 
		' raise error if we can't get a handle to the Win32 Internet API
		If Me.hLib = 0 Then
			Error NOTESFTP_INIT_FAILED, "Could not get handle to WININET.DLL."
		End If
	End Sub
 
	' releases handle to Win32 Internet functions and sets object to Nothing...called by "Delete" statement
	Sub Delete
 
		' log off FTP server if Me.Disconnect has not been called yet
		Me.Disconnect
 
		' raise an error if we can't free our handle to the Win32 Internet API
		If apiInternetCloseHandle(Me.hLib) = False Then
			Error NOTESFTP_DELETE_FAILED, "Could not close handle to WININET.DLL."
		End If
	End Sub
 
	' opens socket and logs into FTP host
	Sub Connect(server$, user$, password$, flags&)
 
		' close any connections we may already have open
		If Me.hConnection <> 0 Then
			apiInternetCloseHandle Me.hConnection
		End If
 
		' log into the FTP host and get a handle to the connection
		Me.hConnection = InternetConnect(Me.hLib, server$, INTERNET_INVALID_PORT_NUMBER, user$, password$, INTERNET_SERVICE_FTP, flags&, 0)
 
		' raise error if we cannot login to the host
		If Me.hConnection = 0 Then
			Error NOTESFTP_CONNECT_FAILED, "Could not connect to host " & server$ & "."
		End If
	End Sub
 
	' releases connection and logs off FTP host
	Sub Disconnect
 
		' if we have a connection open, release it
		If Me.hConnection <> 0 Then
			apiInternetCloseHandle Me.hConnection
		End If
 
		' we have no more open connections
		Me.hConnection = 0
	End Sub
 
	' determines if application is logged into FTP server
	Property Get IsConnected
	' simple check to see if we created a connection...returns True if we have, False if not
		If Me.hConnection <> 0 Then
			IsConnected = True
		Else
			IsConnected = False
		End If
	End Property
	
	' determines current directory on FTP server
	Property Get CurrentDirectory
		Dim sDir As String
 
		' initialize string before passing it to function
		sDir = String(1024, Chr$(0))
 
		' raise error if we cannot get the current directory, otherwise, return the directory name as a string
		If FtpGetCurrentDirectory(Me.hConnection, sDir, 1024) = False Then
			Error NOTESFTP_GETDIR_FAILED, "Could not get current directory on host."
		Else
			CurrentDirectory=sDir
		End If
	End Property
 
	' changes current directory on FTP host
	Sub ChangeDirectory(sDir$)
 
		' raise error if directory could not be changed
		If FtpSetCurrentDirectory(Me.hConnection, sDir$) = False Then
			Error NOTESFTP_SETDIR_FAILED, "Could not set current directory on host."
		End If
	End Sub
 
	' creates new directory on FTP host
	Sub CreateDirectory(sDir$)
 
		' raise an error if we cannot create a new directory
		If FtpCreateDirectory(Me.hConnection, sDir$) = False Then
			Error NOTESFTP_CREATEDIR_FAILED, "Could not create directory on host."
		End If
	End Sub
 
	' removes a directory from an FTP host
	Sub RemoveDirectory(sDir$)
 
		' raise an error if we cannot remove the directory from the host
		If FtpRemoveDirectory(Me.hConnection, sDir$) = False Then
			Error NOTESFTP_DELETEDIR_FAILED, "Could not delete directory from host."
		End If
	End Sub
 
	' uploads a file to an FTP host
	Sub PutFile(localFile$, remoteFile$, transferType&)
 
		' raise an error if we cannot submit the file to the host
		If FtpPutFile(Me.hConnection, localFile$, remoteFile$, transferType&, 0) = False Then
			Error NOTESFTP_PUTFILE_FAILED, "Could not upload file to host."
		End If
	End Sub
 
	' downloads a file from an FTP host
	Sub GetFile(remoteFile$, localFile$, transferType&)
 
		' raise an error if file cannot be downloaded from host
		If FtpGetFile(Me.hConnection, remoteFile$, localFile$, False, FILE_ATTRIBUTE_NORMAL, transferType& Or INTERNET_FLAG_RELOAD, 0) = False Then
			Error NOTESFTP_GETFILE_FAILED, "Could not download file from host."
		End If
	End Sub
 
	' renames a file on an FTP host
	Sub RenameFile(existingFile$, newFile$)
 
		' raise an error if file cannot be renamed on host
		If FtpRenameFile(Me.hConnection, existingFile$, newFile$) = False Then
			Error NOTESFTP_RENAMEFILE_FAILED, "Could not rename file on host."
		End If
	End Sub
 
	' deletes a file from an FTP host
	Sub DeleteFile(remoteFile$)
 
		' raise an error if file cannot be delete from server
		If FtpDeleteFile(Me.hConnection, remoteFile$) = False Then
			Error NOTESFTP_DELETEFILE_FAILED, "Could not delete file from host."
		End If
	End Sub
 
	' returns a list of files and directories in current directory on FTP host
	Function Dir(dirSpec$) As Variant
		Dim retArray() As String
		Dim hFind&
		Dim pData As WIN32_FIND_DATA
		Dim nCt%
 
		' get handle to first file
		hFind& = FtpFindFirstFile(Me.hConnection, dirSpec$, pData, 0, 0 )
 
		' continue on if we found a file
		If hFind& <> 0 Then
 
			' initialize array and plug in first element
			nCt%=0
			Redim retArray(nCt%)
			retArray(nCt%) = Left(pData.cFileName, Instr(1, pData. cFileName, String(1, 0)) - 1)
 
			' find all files in the current directory and place their names into an array
			Do While InternetFindNextFile(hFind&, pData) <> 0
				nCt%=nCt%+1
				Redim Preserve retArray(nCt%)
				retArray(nCt%) = Left(pData.cFileName, Instr(1, pData.cFileName, String(1, 0)) - 1)
				pData.cFileName = String$(MAX_PATH, 0)
			Loop
 
			' close the handle we have on the first file
			apiInternetCloseHandle hFind&
 
			' return the results
			Me.Dir = retArray
		End If
	End Function
 
End Class
Open in New Window
Accepted Solution
 
 
20080236-EE-VQP-29 / EE_QW_2_20070628