If you don't know it, have a look at http://www.photools.com/
These Scripts can be used any way, but also without any kind of warranty!
If you don't agree, please leave now.
= new Script
= updated Script
Multi Database Transmission V 1.2 (06-Jun-2003) - This script transmits Images from a SourceDB to a TargetDB, preserving all Category-Assignments and Property-Entries. (And, *g*, if Mario would give us an updated Timestamp for the DatabaseImageRecords, we could merge Databases by checking which Entry is newer. Think about mobile IMatch.)
Remove Empty Categories from Database V 1.0 (30-May-2003) - This script removes all 'empty'-Categories from the active Database.
OffLineCache Garbage Collector V 1.0 (28-Jun-2003) - This script checks all existing Images in OfflineCacheFolder of the active Database and deletes ownerless OLC-Images. Additionally you can select some Categories from which you want delete the Images OfflineCache-pendants.
Photoshop Conversion (PS 5.5 + 6) V 0.9 (02-Jul-2003) - This Script combines the ManagementPower of IMatch with the ImageManipulationPower of Adobes Photoshop 6.0 in an easy to use way. This Script I have written together with Klaus Schwarzburg. Many thanks for your help, Klaus.
lcms Webgallery Creator V 0.1 (05-Oct-2002) - This script enhance the original Webgallery-Creator-Script with an ICC-Conversion-feature.
little Batch Converter V 1.2 (26-Jun-2003) - This script create resized copies, optionally with ICC-Conversion for Tiff- and Jpeg-sources. Can work with OfflineCacheImages instead of originals and can transmit all Property-, Category- and IPTC-data to the copies.
Registry Functions V 1.0 (01-Nov-2002) - A littleHelper-Script to put and retrieve Data to/from Registry in its correct DataTypes. VB usually provides only the StringType. With this Lib you can store every DataType to Registry (Byte, Integer, Long, Double, Decimal, Boolean, Variant, ...).
Debug Messages V 1.0 (08-Nov-2002) - A littleHelper-Script which handles Debugoutput in Priorityclasses. With this you can have good Informationoutput when you develope a Script and a less or no Output when run the Script in Productivity-Mode. Your DebugmessagePoints can stay in code without any (auswirkung). Usefull for future changes on your code.
Explanation
MainScript: hnSample_FncDebugMsg.bas
Needed Modules: [hnFncDebugMsg.obm]
hnSample_FncDebugMsg.bas: (122 lines / 83 real codelines / 1 Sub / 4 Functions / 0 Properties)
1| '#uses "hn273\hnFncDebugMsg.obm" 2| 3| Option Explicit 4| 5| 6| Dim MyVeryImportantVar As String 7| 8| 9| Sub Main 10| 11| 12| '**************************************** 13| 'See 'hnFncDebugMsg.obm' for explanation 14| dbgmsg = True 15| PromptMe = False 16| 'DbgOutPutPriority = low 17| '**************************************** 18| 19| 20| 21| Dim PriorityClasses(0 To 3) As String 22| PriorityClasses(0) = "low" 23| PriorityClasses(1) = "medium" 24| PriorityClasses(2) = "high" 25| PriorityClasses(3) = "Production" 26| 27| MyVeryImportantVar = "I'm empty :(" 28| 29| Begin Dialog UserDialog 590,308,"DebugMessages-DEMO",.MainDlg_Func ' %GRID:10,7,1,1 30| Text 20,189,290,28,"Please Select a PriorityClass and then" & vbCr & "press the Run-Button",.Text1 31| DropListBox 20,217,190,91,PriorityClasses(),.DPC 32| PushButton 20,245,190,21,"Run TestScript",.Run 33| PushButton 310,245,270,21,"close Dialog",.PushButton2 34| Text 20,7,560,21,"This is a little SampleScript. It demonstrates how the DebugMessagesScript works.",.Text2 35| Text 20,42,560,56,"To see the Output you must open the DebugWindow." & vbCr & vbCr & "If it is not open now, close this Dialog, open it and start the Script again. Otherwise you will see nothing, ;)",.Text3 36| Text 20,112,560,56,"For explanation you can go to my little IMatch-Section on my private homepage: http://horst.nogajski.de/IMatch/" & vbCr & "There you find all Scripts and also all explanations." & vbCr & "The Button go-to-explanation brings you straight to the explanation of this Script",.Text4 37| PushButton 310,217,270,21,"go to Explanation of this Script",.URL 38| End Dialog 39| Dim dlg As UserDialog 40| 41| dlg.DPC = 2 42| 43| If Dialog(dlg) >= 0 Then Exit Sub 44| 45| 46| End Sub 47| 48| 49| Private Function MainDlg_Func(DlgItem$, Action%, SuppValue&) As Boolean 50| Select Case Action% 51| Case 1 52| Case 2 53| Select Case DlgItem$ 54| Case "URL" 55| Dim explanation As String 56| Dim SinnDesLebens As Variant 57| explanation = URLShortCut("http://horst.nogajski.de/imatch/index.php?show=DebugMessages&sub=debugmsg.explanation.inc.php#Show","DebugMsgExplanation.url") 58| If explanation <> "" Then 59| SinnDesLebens = Application.ShellExecute("open",explanation) 60| 'If CInt(SinnDesLebens) <> 42 Then Error_ 61| End If 62| MainDlg_Func = True 63| Case "Run" 64| DbgOutPutPriority = CLng(DlgValue("DPC")) 65| Debug.Print vbNewLine & vbNewLine & vbNewLine & vbNewLine 66| Debug.Print "#######################" 67| Debug.Print "The TestScript starts:" 68| TestScript1() 69| TestScript2() 70| Debug.Print "TestScript has finished" 71| Debug.Print "#######################" 72| MyVeryImportantVar = "I'm empty :(" 73| MainDlg_Func = True 74| End Select 75| End Select 76| End Function 77| 78| Private Function TestScript2() 79| 80| DoDbgMsg(low,"TestScript2",FunctionEntry,"This Msg has PriorityClass low.") 81| DoDbgMsg(medium,"TestScript2",FunctionEntry,"This Msg has PriorityClass medium.") 82| DoDbgMsg(high,"TestScript2",FunctionEntry,"This Msg has PriorityClass high.") 83| DoDbgMsg(production,"TestScript2",FunctionEntry,"This Msg has PriorityClass Production.") 84| DoDbgMsg(medium,"TestScript2",FunctionEntry,"Here comes my Message." & vbCr & "My very Important Var has Value: " & MyVeryImportantVar) 85| 86| Dim AlsoImportantVar As String 87| AlsoImportantVar = TestScript1() 88| DoDbgMsg(Production,TestScript2,duringFunctionProcess,AlsoImportantVar) 89| 90| 91| MyVeryImportantVar = "Uuups, I have a new Value :)" 92| DoDbgMsg(Production,"TestScript2",FunctionExit,"(" & Now & ") - The very Important Var has Value: " & MyVeryImportantVar) 93| 94| End Function 95| 96| Private Function TestScript1() 97| 98| Dim StrVar As String 99| StrVar = StrVar & "Var: dbgmsg = " & CStr(dbgmsg) & vbCr 100| StrVar = StrVar & "Var: PromptMe = " & CStr(PromptMe) & vbCr 101| StrVar = StrVar & "Var: DbgOutPutPriority = " & CStr(DbgOutPutPriority) & vbCr 102| TestScript1 = StrVar 103| 104| End Function 105| 106| Private Function URLShortCut(ByVal URL As String, Optional filename As String = "hn273ShortCut.url") As String 107| 108| URLShortCut = "" 109| 110| Dim FN As Integer 111| FN = FreeFile 112| filename = Environ("TEMP") & "\" & filename 113| Open filename For Output As #FN 114| Print #FN, "[InternetShortcut]" 115| Print #FN, "URL=" & URL 116| Print #FN, "Modified=9038803A3E9DC20120" 117| Close #FN 118| 119| URLShortCut = filename 120| 121| End Function 122|