Skip to content

Commit

Permalink
minor changes for release
Browse files Browse the repository at this point in the history
  • Loading branch information
OlimilO1402 committed Jan 16, 2022
1 parent 1ed109b commit bd3c1a2
Show file tree
Hide file tree
Showing 5 changed files with 29 additions and 22 deletions.
33 changes: 17 additions & 16 deletions Forms/Form1.frm → Forms/FMain.frm
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
VERSION 5.00
Begin VB.Form FrmEmail
Caption = "Form1"
Begin VB.Form FMain
Caption = "FMain"
ClientHeight = 5535
ClientLeft = 120
ClientTop = 465
ClientWidth = 8415
Icon = "Form1.frx":0000
LinkTopic = "Form1"
Icon = "FMain.frx":0000
LinkTopic = "FMain"
ScaleHeight = 5535
ScaleWidth = 8415
StartUpPosition = 3 'Windows-Standard
Expand Down Expand Up @@ -38,9 +38,9 @@ Begin VB.Form FrmEmail
End
Begin VB.ListBox LBFiles
Height = 2010
ItemData = "Form1.frx":1782
ItemData = "FMain.frx":1782
Left = 4800
List = "Form1.frx":1784
List = "FMain.frx":1784
OLEDragMode = 1 'Automatisch
OLEDropMode = 1 'Manuell
TabIndex = 1
Expand Down Expand Up @@ -126,7 +126,7 @@ Begin VB.Form FrmEmail
Width = 495
End
End
Attribute VB_Name = "FrmEmail"
Attribute VB_Name = "FMain"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Expand All @@ -135,8 +135,10 @@ Option Explicit
Private m_Email As StdMail

Private Sub Form_Load()
Me.Caption = "MAPI Sendmail" & " v" & App.Major & "." & App.Minor & "." & App.Revision
Set m_Email = New StdMail
End Sub

Private Sub Form_Resize()
Dim L As Single, T As Single, W As Single, H As Single
L = LBFiles.Left: W = Me.ScaleWidth - L: H = LBFiles.Height
Expand All @@ -154,33 +156,30 @@ Private Sub BtnFillTestEmail_Click()
LBFiles.AddItem App.Path & "\Resources\Test2.pdf"
End Sub

'Private Sub Command4_Click()
' Debug.Print GetHtmlEmail.ToHtmlStr
'End Sub

Private Sub BtnEmailStart_Click()
Set m_Email = New StdMail
With m_Email
.IsUnicode = True
.RecipientAddTo TxtRecpTo.Text
.RecipientAddCC TxtRecpCC.Text
.Subject = TxtSubject.Text '"Hello for Test"
.BodyText = TxtBodyText.Text 'GetHtmlEmail.ToHtmlStr
.Subject = TxtSubject.Text
.BodyText = TxtBodyText.Text
Dim i As Long
For i = 0 To LBFiles.ListCount - 1
.FileAdd LBFiles.List(i)
Next
'.FileAdd App.Path & "\Resources\Test1.pdf"
'.FileAdd App.Path & "\Resources\Test2.pdf"
End With
m_Email.Start
End Sub

Private Function AddRecipientsTo(TB As TextBox, eml As StdMail)
'
End Function

Private Sub BtnEmailLogin_Click()
m_Email.Login "XXXXXXXXXXXXXXXXXXXX", "XXXXXXXXXXXXXXXXXXXX"
End Sub

Private Sub LBFiles_OLEDragDrop(Data As DataObject, Effect As Long, Button As Integer, Shift As Integer, X As Single, Y As Single)
If Data.GetFormat(vbCFFiles) Then
Dim f
Expand All @@ -189,6 +188,7 @@ Private Sub LBFiles_OLEDragDrop(Data As DataObject, Effect As Long, Button As In
Next
End If
End Sub

Function GetFileName(ByVal aPFN As String) As String
Dim pos As Long: pos = InStrRev(aPFN, "\")
If pos = 0 Then GetFileName = aPFN: Exit Function
Expand All @@ -200,6 +200,7 @@ Private Sub TxtRecpTo_LostFocus()
'soll man direkt in die Email schreiben, ja wegen SessionID muss man direkt in die Email schreiben
'd.h
End Sub

Public Function getHTMLText() As String
Dim s As String: s = ""
s = s & "<html>" & vbCrLf
Expand Down Expand Up @@ -252,7 +253,6 @@ Public Function getHTMLText() As String
getHTMLText = s
End Function


Public Function GetHtmlEmail() As HtmlElem
Dim html As HtmlElem
Set html = New_HtmlElem("html")
Expand Down Expand Up @@ -302,6 +302,7 @@ Public Function GetHtmlEmail() As HtmlElem
End With
Set GetHtmlEmail = html
End Function

'Sub MapiSimpleSendMail(Files() As String, ToEmailAddress As String, toName As String)
'
' Dim aMAPIMessage As MAPIMessage
Expand Down
File renamed without changes.
Binary file removed MapiSendmail.zip
Binary file not shown.
2 changes: 1 addition & 1 deletion Modules/MNew.bas
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Attribute VB_Name = "MNew"
Option Explicit

Sub Main()
FrmEmail.Show
FMain.Show
End Sub

Public Function New_HtmlElem(aName As String) As HtmlElem
Expand Down
16 changes: 11 additions & 5 deletions PMapiSendmail.vbp
Original file line number Diff line number Diff line change
@@ -1,21 +1,27 @@
Type=Exe
Reference=*\G{00020430-0000-0000-C000-000000000046}#2.0#0#C:\Windows\SysWOW64\stdole2.tlb#OLE Automation
Form=Forms\Form1.frm
Reference=*\G{00020430-0000-0000-C000-000000000046}#2.0#0#C:\WINDOWS\SysWow64\stdole2.tlb#OLE Automation
Form=Forms\FMain.frm
Module=MNew; Modules\MNew.bas
Class=StdMail; Classes\StdMail.cls
Class=HtmlElem; Classes\HtmlElem.cls
ResFile32="Resources\MyRes.RES"
Startup="FrmEmail"
IconForm="FMain"
Startup="FMain"
HelpFile=""
Title="PMapiSendmail"
ExeName32="MapiSendmail.exe"
Command32=""
Name="PMapiSendmail"
HelpContextID="0"
CompatibleMode="0"
MajorVer=1
MinorVer=0
RevisionVer=0
AutoIncrementVer=0
RevisionVer=1
AutoIncrementVer=1
ServerSupportFiles=0
VersionCompanyName="MBO-Ing.com"
VersionLegalCopyright="MBO-Ing.com"
VersionProductName="MAPI Sendmail"
CompilationType=0
OptimizationType=0
FavorPentiumPro(tm)=0
Expand Down

0 comments on commit bd3c1a2

Please sign in to comment.