Skip to content

Commit

Permalink
### Added
Browse files Browse the repository at this point in the history
- Access x64 Support. Should now work on Access 2010+ x64.
  • Loading branch information
ruddj committed Feb 9, 2018
1 parent a6a7da1 commit a8f9ed2
Show file tree
Hide file tree
Showing 9 changed files with 64 additions and 51 deletions.
8 changes: 7 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/)
and this project adheres to [Semantic Versioning](http://semver.org/).

## [Unreleased]

## [5.2.0 - 2018-02-09
### Added
- Access x64 Support. Should now work on Access 2010+ x64.

### Changed
- In Results entry pressing up and down arrow in name selection will bring up dropdown list of names, making it easier to select name without using mouse.
- When Importing students will verify Age is number and DoB is Date. Useful to remove header line.
Expand Down Expand Up @@ -211,7 +216,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
- Ordered Competitors handled differently: Table held locally. Does not delete old but overwrites them.


[Unreleased]: https://github.com/ruddj/SportsAdmin/compare/v5.1.4...HEAD
[Unreleased]: https://github.com/ruddj/SportsAdmin/compare/v5.2.0...HEAD
[5.2.0]: https://github.com/ruddj/SportsAdmin/compare/v5.1.4...v5.2.0
[5.1.4]: https://github.com/ruddj/SportsAdmin/compare/v5.1.3...v5.1.4
[5.1.3]: https://github.com/ruddj/SportsAdmin/compare/v5.1.2...v5.1.3
[5.1.2]: https://github.com/ruddj/SportsAdmin/compare/v5.1.1...v5.1.2
Expand Down
2 changes: 0 additions & 2 deletions Source/forms/EnterCompetitors.bas
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ Begin Form
NavigationButtons = NotDefault
DividingLines = NotDefault
AllowAdditions = NotDefault
FilterOn = NotDefault
DefaultView =0
ScrollBars =0
ViewsAllowed =1
Expand All @@ -22,7 +21,6 @@ Begin Form
Right =17985
Bottom =9705
HelpContextId =110
Filter ="[HE_Code] = 1541"
RecSrcDt = Begin
0xf2f778be6e4ae240
End
Expand Down
2 changes: 1 addition & 1 deletion Source/installs/Setup.nsi
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
!include "..\NsisMultiUser\Demos\Common\Utils.nsh"

!define PRODUCT_NAME "Sports Administrator" ; name of the application as displayed to the user
!define VERSION "5.1.4" ; main version of the application (may be 0.1, alpha, beta, etc.)
!define VERSION "5.2.0" ; main version of the application (may be 0.1, alpha, beta, etc.)
!define PROGEXE "Sports.accdr" ; main application filename
!define COMPANY_NAME "Sports Administrator" ; company, used for registry tree hierarchy
!define PRODUCT_FOLDER "SportsAdmin"
Expand Down
21 changes: 11 additions & 10 deletions Source/modules/API Calls - Open Folder.bas
Original file line number Diff line number Diff line change
Expand Up @@ -12,27 +12,28 @@ Option Explicit
'Terry Kreft

Private Type BROWSEINFO
hOwner As Long
pidlRoot As Long
hOwner As LongPtr
pidlRoot As LongPtr
pszDisplayName As String
lpszTitle As String
ulFlags As Long
lpfn As Long
lParam As Long
lpfn As LongPtr
lParam As LongPtr
iImage As Long
End Type

Private Declare Function SHGetPathFromIDList Lib "shell32.dll" Alias _
"SHGetPathFromIDListA" (ByVal pidl As Long, _
ByVal pszPath As String) As Long
Private Declare PtrSafe Function SHGetPathFromIDList Lib "shell32.dll" Alias _
"SHGetPathFromIDListA" (ByVal pidl As LongPtr, _
ByVal pszPath As String) As Boolean

Private Declare Function SHBrowseForFolder Lib "shell32.dll" Alias _
Private Declare PtrSafe Function SHBrowseForFolder Lib "shell32.dll" Alias _
"SHBrowseForFolderA" (lpBrowseInfo As BROWSEINFO) _
As Long
As LongPtr

Private Const BIF_RETURNONLYFSDIRS = &H1

Public Function BrowseFolder(szDialogTitle As String) As String
Dim X As Long, bi As BROWSEINFO, dwIList As Long
Dim X As Boolean, bi As BROWSEINFO, dwIList As LongPtr
Dim szPath As String, wPos As Integer

With bi
Expand Down
22 changes: 12 additions & 10 deletions Source/modules/API Calls - Open-Save File Dialog.bas
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ Option Explicit

Type tagOPENFILENAME
lStructSize As Long
hwndOwner As Long
hInstance As Long
hwndOwner As LongPtr
hInstance As LongPtr
strFilter As String
strCustomFilter As String
nMaxCustFilter As Long
Expand All @@ -32,14 +32,15 @@ Type tagOPENFILENAME
nFileExtension As Integer
strDefExt As String
lCustData As Long
lpfnHook As Long
lpfnHook As LongPtr
lpTemplateName As String
End Type
Declare Function aht_apiGetOpenFileName Lib "comdlg32.dll" _

Declare PtrSafe Function aht_apiGetOpenFileName Lib "comdlg32.dll" _
Alias "GetOpenFileNameA" (OFN As tagOPENFILENAME) As Boolean
Declare Function aht_apiGetSaveFileName Lib "comdlg32.dll" _
Declare PtrSafe Function aht_apiGetSaveFileName Lib "comdlg32.dll" _
Alias "GetSaveFileNameA" (OFN As tagOPENFILENAME) As Boolean
Declare Function CommDlgExtendedError Lib "comdlg32.dll" () As Long
Declare PtrSafe Function CommDlgExtendedError Lib "comdlg32.dll" () As Long

' Definition of Flags
' https://msdn.microsoft.com/en-us/library/aa238842(v=vs.60).aspx
Expand Down Expand Up @@ -119,6 +120,7 @@ Dim varFileName As Variant
End If
GetOpenFile = varFileName
End Function

Function ahtCommonFileOpenSave( _
Optional ByRef Flags As Variant, _
Optional ByVal InitialDir As Variant, _
Expand All @@ -127,7 +129,6 @@ Function ahtCommonFileOpenSave( _
Optional ByVal DefaultExt As Variant, _
Optional ByVal FileName As Variant, _
Optional ByVal DialogTitle As Variant, _
Optional ByVal hWnd As Variant, _
Optional ByVal OpenFile As Variant) As Variant
' This is the entry point you'll use to call the common
' file open/save dialog. The parameters are listed
Expand Down Expand Up @@ -160,15 +161,14 @@ Dim fResult As Boolean
If IsMissing(DefaultExt) Then DefaultExt = ""
If IsMissing(FileName) Then FileName = ""
If IsMissing(DialogTitle) Then DialogTitle = ""
If IsMissing(hWnd) Then hWnd = Application.hWndAccessApp
If IsMissing(OpenFile) Then OpenFile = True
' Allocate string space for the returned strings.
strFileName = Left(FileName & String(256, 0), 256)
strFileTitle = String(256, 0)
' Set up the data structure before you call the function
With OFN
.lStructSize = Len(OFN)
.hwndOwner = hWnd
.lStructSize = LenB(OFN)
.hwndOwner = Application.hWndAccessApp
.strFilter = Filter
.nFilterIndex = FilterIndex
.strFile = strFileName
Expand Down Expand Up @@ -213,6 +213,7 @@ Dim fResult As Boolean
ahtCommonFileOpenSave = vbNullString
End If
End Function

Function ahtAddFilterItem(strFilter As String, _
strDescription As String, Optional varItem As Variant) As String
' Tack a new chunk onto the file filter.
Expand All @@ -225,6 +226,7 @@ Function ahtAddFilterItem(strFilter As String, _
strDescription & vbNullChar & _
varItem & vbNullChar
End Function

Private Function TrimNull(ByVal strItem As String) As String
Dim intPos As Integer
intPos = InStr(strItem, vbNullChar)
Expand Down
4 changes: 1 addition & 3 deletions Source/modules/Globals.bas
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,7 @@ Global GlobalPlaceChange As Boolean
Global DisplayRecords As Integer

Global Const DEMO = False
Global Const DEMOcompetitors = 75
Global Const DEMOmessage = "This is a demonstration version of the Sports Administrator. The demo version is limited to 75 competitors. If you wish to purchase the full version of Sports Administrator, please read the About information from the Main Menu."
Global Const DEMOmessage2 = "This is a demonstration version of the Sports Administrator. The carnival you are attempting to make active has more than 75 competitors. The demo version is limited to 75 competitors. If you wish to purchase the full version of Sports Administrator, please read the About information from the Main Menu."

Global Const aDebug = False
Global EventAgeArray() As String

Expand Down
12 changes: 10 additions & 2 deletions Source/modules/VersionDetails.bas
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,16 @@ Option Compare Database
Option Explicit


Global Const VersionNumber = "5.1.4"
Global Const VersionDate = "(25/July/2017)"
Global Const VersionNumber = "5.2.0"
Global Const VersionDate = "(09/Feb/2018)"

' Version 5.2.0 - 2018-02-09

' Access x64 Support. Should now work on Access 2010+ x64.
' In Results entry pressing up and down arrow in name selection will bring up dropdown list of names, making it easier to select name without using mouse.
' When Importing students will verify Age is number and DoB is Date. Useful to remove header line.
' When choosing Sort by Place it would run the script to update Final Status generating an error if setting it to completed.
' Maintain Event Order can now start from 1 when no events have been numbered

' Version 5.1.4 - 2017-07-25
'
Expand Down
44 changes: 22 additions & 22 deletions Source/modules/_API - Clipboard Routines.bas
Original file line number Diff line number Diff line change
Expand Up @@ -2,36 +2,36 @@ Option Compare Database
Option Explicit

'Windows API declarations
Private Declare Function GetActiveWindow Lib "user32" () As Long
Private Declare PtrSafe Function GetActiveWindow Lib "user32" () As LongPtr

Private Declare Function GetClassName Lib "user32" Alias "GetClassNameA" _
(ByVal hWnd As Long, ByVal lpClassName As String, _
ByVal nMaxCount As Long) As Long
Private Declare PtrSafe Function GetClassName Lib "user32" Alias "GetClassNameA" _
(ByVal hWnd As LongPtr, ByVal lpClassName As String, _
ByVal nMaxCount As LongPtr) As Long

Private Declare Function GetWindow Lib "user32" _
(ByVal hWnd As Long, ByVal wCmd As Long) As Long
Private Declare PtrSafe Function GetWindow Lib "user32" _
(ByVal hWnd As LongPtr, ByVal wCmd As Long) As Long

Private Declare Function OpenClipboard Lib "user32" _
(ByVal hWnd As Long) As Long
Private Declare PtrSafe Function OpenClipboard Lib "user32" _
(ByVal hWnd As LongPtr) As Long

Private Declare Function GetClipboardData Lib "user32" _
(ByVal wFormat As Long) As Long
Private Declare PtrSafe Function GetClipboardData Lib "user32" _
(ByVal wFormat As Long) As LongPtr

Private Declare Function CloseClipboard Lib "user32" () As Long
Private Declare PtrSafe Function CloseClipboard Lib "user32" () As Long

Private Declare Function GlobalAlloc Lib "kernel32" _
(ByVal wFlags As Long, ByVal dwBytes As Long) As Long
Private Declare PtrSafe Function GlobalAlloc Lib "kernel32" _
(ByVal wFlags As Long, ByVal dwBytes As LongPtr) As LongPtr

Private Declare Function GlobalLock Lib "kernel32" _
(ByVal hMem As Long) As Long
Private Declare PtrSafe Function GlobalLock Lib "kernel32" _
(ByVal hMem As LongPtr) As LongPtr

Private Declare Function lstrcpy Lib "kernel32" _
Private Declare PtrSafe Function lstrcpy Lib "kernel32" _
(ByVal lpString1 As Any, _
ByVal lpString2 As Any) As Long
ByVal lpString2 As Any) As LongPtr

Private Declare Function GlobalUnlock Lib "kernel32" (ByVal hMem As Long) As Long
Private Declare PtrSafe Function GlobalUnlock Lib "kernel32" (ByVal hMem As LongPtr) As Long

Private Declare Function GlobalSize Lib "kernel32" (ByVal hMem As Long) As Long
Private Declare PtrSafe Function GlobalSize Lib "kernel32" (ByVal hMem As LongPtr) As LongPtr

'Constants used by Windows API calls
Public Const CF_TEXT = 1
Expand All @@ -51,10 +51,10 @@ Function GetClipboardText() As String
'Comments: If only we had the VB function Clipboard.GetText() !
'***************************************************************************

Dim lngMemBlockHandle As Long
Dim lngMemPointer As Long
Dim lngMemBlockHandle As LongPtr
Dim lngMemPointer As LongPtr
Dim strText As String
Dim lngRetVal As Long
Dim lngRetVal As LongPtr


' Open the Clipboard
Expand Down
Binary file modified Sports.accdb
Binary file not shown.

0 comments on commit a8f9ed2

Please sign in to comment.