Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Ive gotten as far as noting the property OFN_ENABLESIZING but dont know how to apply it? Any help would be appreciated
*-- Class: acxcommondialog (e:\marciapresents\activex\libs\activex.vcx)
*-- ParentClass: olecontrol
*-- OLEObject = C:\WINDOWS\system32\comdlg32.ocx
*
Define Class acxcommondialog As OleControl
Height = 37
Width = 36
*-- The folder from which the file(s) were selected
cpath = (Fullpath( Curdir() ))
*-- Caption for the open file dialog
ccaption = "Select one or more files"
*-- Default file extension to use if the user types something in the box that does not have an extension
cextension = ""
*-- The list of selected files from the dialog
cselectedfiles = ""
*-- Types of files to display such as Tables | *.dbf
cfilter = ""
Name = "acxcommondialog"
*-- sets the required flags, displays the dialog and parses the return values
Procedure getfiles
#Define cdlOFNReadOnly 1 && Checks Read Only check box for Open and Save As dialog boxes.
#Define cdlOFNOverwritePrompt 2 && Generates a message box if the selected file already exists.
#Define cdlOFNHideReadOnly 4 && Hides the Read Only check box.
#Define cdlOFNNoChangeDir 8 && Sets the current directory to what it was when the dialog box was invoked.
#Define cdlOFNHelpButton 16 && Causes the dialog box to display the Help button.
#Define cdlOFNNoValidate 256 && Allows invalid characters in the returned file name.
#Define cdlOFNAllowMultiselect 512 && Allows the File Name list box to have multiple selections.
#Define cdlOFNExtensionDifferent 1024 && Extension of returned file name is different from the one set by DefaultExt.
#Define cdlOFNPathMustExist 2048 && User can enter only valid path names.
#Define cdlOFNFileMustExist 4096 && User can enter only names of existing files.
#Define cdlOFNCreatePrompt 8192 && Asks if the user wants to create a file that does not currently exist.
#Define cdlOFNShareAware 16384 && Sharing violation errors will be ignored.
#Define cdlOFNNoReadOnlyReturn 32768 && The returned file will not have the Read Only attribute set.
#Define cdlOFNNoLongNames 262144 && No long filenames.
#Define cdlOFNExplorer 524288 && Windows 95 Open A File dialog box template.
#Define cdlOFNNoDereferenceLinks 1048576 && No shortcuts.
#Define cdlOFNLongNames 2097152 && Long filenames.
Local lcCurDir, lnFlags, lcFiles, lnI
*** Save the current directory
lcCurDir = Fullpath( Curdir() )
*** Set the required flags
*** This demo uses the common dialog to allow users to select
*** multiple files. You could easily modify this class to be totally
*** configurable and use it for all your getfile() and putfile() dialogs
*** simply by adding properties for each of thes configurable options
*** and setting the flags depending on their values
lnFlags = cdlOFNExplorer +;
cdlOFNHideReadOnly +;
cdlOFNAllowMultiselect +;
cdlOFNPathMustExist +;
cdlOFNFileMustExist
With This
.Flags = lnFlags
.DialogTitle = .ccaption
.Defaultext = .cextension
.InitDir = .cpath
.Filter = .cfilter
If Not Empty( .Filter )
.FilterIndex = 1
Endif
*** Display the dialog
.ShowOpen()
*** If multiple files were selected, .FileName consists of the path followed by a
*** separator followed by the list of files selected separated by separators. If
*** only one file was selected, .FileName is the complete path to the file.
lcFiles = .FileName
*** Individual files are separated with .NULLS.
*** so if we have any in the string returned
*** we know that we have more than one file
If Chr( 0 ) $ lcFiles
*** But we have to replace all the nulls with
*** another character because GETWORDNUM() does
*** not see nulls as separators - do not use a space
*** in case there are spaces in file or folder names
lcFiles = Strtran( lcFiles, Chr( 0 ), [~], 1, -1, 1 )
.cpath = Getwordnum( lcFiles, 1, [~] )
Else
.cpath = Addbs( Justpath( lcFiles ) )
Endif
lcFiles = Alltrim( Strtran( lcFiles, .cpath, [], 1, 1, 1 ) )
.cselectedfiles = []
For lnI = 1 To Getwordcount( lcFiles, [~])
.cselectedfiles = .cselectedfiles + Addbs( .cpath ) + Getwordnum( lcFiles, lnI, [~] ) + Chr( 13 ) + Chr( 10 )
Endfor
Endwith
*** restore current directory
Cd ( lcCurDir )
Endproc
Enddefine
#DEFINE OFN_HIDEREADONLY 4
#DEFINE cdOFNNOCHANGEDIR 8
#DEFINE cdOFNEXTENSIONDIFFERENT 1024
#DEFINE cdOFNPATHMUSTEXIST 2048 && 0x800
#DEFINE cdOFNCREATEPROMPT 8192 && 0x2000
#DEFINE cdOFNEXPLORER 524288 && 0x80000
#DEFINE cdOFNDONTADDTORECENT 33554432 && 0x2000000
#DEFINE cdOFNENABLESIZING 0x800000
lnFlags = cdOFNPATHMUSTEXIST + cdOFNEXTENSIONDIFFERENT +;
cdOFNCREATEPROMPT + cdOFNHIDEREADONLY + cdOFNNOCHANGEDIR+ cdOFNENABLESIZING