Hello folks,
I'm about to leave for two weeks vacation, but
before that I'd like to donate you little bit of my knowledge on MapInfo
undocumented stuff. I haven't figured them out yet, but maybe someone could
explain how they work or what are they build for (since not
documented).
Functions:
SetHooverInfo(strDummy,strDummy)
GetHooverInfo(strDummy)
HooverCommand(strDummy)
Clause:
On Find Using statement clause
Closestobj
Features (or flaws):
An Error$() fuction you are able to extract the
error text string of a specific error number. How by generating User-defined
error with Error statement and catching the the error text you are able to
extrect other text resources used in MapInfo dialogs. (Jacques, this could be
handy on detecting language identification and language specified dialogs!) It
also serves as built-in functionality to peak in Mapinfo internals.
The following code will print out all of them. Use
it at your own risk though. If you decide to try it, I would be dead curious to
see your prints, since I only got Finnish and English versions on
board.
Regards,
Anssi
'***********************************
Include "mapbasic.def" Declare Sub Main Declare Sub Errorlist Global i, iRange As Integer Global strDump As String Sub Main CLS Dim fname As String iRange = 2^16/2 fname = PathToDirectory$(TempFileName$("")) & "mapinfo.err" Open File fname For Output As #1 Charset "WindowsLatin1" i = 1 ProgressBar "Checking errorlist..." Calling Errorlist Range iRange If CommandInfo(CMD_INFO_STATUS) Then Note "Operation completed" Else Note "Operation interrupted" End If Close File #1 Run Program "Notepad.exe " & fname End Sub Sub Errorlist Dim iError, iLoop, j As Integer Dim strError As String Dim start_time As Float start_time = Timer() OnError Goto PRINTERROR Do While i < iRange And Timer() - start_time < 1 'for some reason following three codes will freeze the machine If i Not In(2209,2212,6244) Then Error i End If BACKAGAIN: i = i+1 Loop If i > iRange-1 Then ProgressBar = -1 Else ProgressBar = i End If Exit Sub PRINTERROR: strError = LTrim$(RTrim$(Error$())) iError = Err() strDump = Format$(iError,"00000") & " " & Right$(strError,Len(strError)-InStr(1,strError,")")) iLoop = 1 Do While iLoop iLoop = InStr(iLoop+1,strDump,Chr$(10)) If iLoop Then strDump = Left$(strDump, iLoop) & Chr$(9) & Chr$(9) & Right$(strDump, Len(strDump)-iLoop) End If Loop
If Right$(strError,Len(Str$(i))+1) <> Str$(i) & "." Then Print #1, strDump End If If i < iRange Then Resume BACKAGAIN Else Exit Sub End If End Sub '*********************************** |
- Re: MI Undocumented (revisited) Anssi Joutsiniemi
- Re: MI Undocumented (revisited) Gary Schwartz
- SUM: MI Undocumented (revisited) Anssi Joutsiniemi