Am currently rewriting (3rd? 4th? 6th? 10th? time over the years) a data manager I've used for about 25 years (one of the first PBWin projects I tackled when I came from the Dark Side (DOS)). At any rate on another thread Borje's WinSpy was mentioned and I thought I'd take another look at it. I tried it on ExplorerPlus (file manager) but it didn't do much for me.
So I thought I'd try it on the something familiar (my DB). Here'w what it looked at: http://www.SwedesDock.com/powerbasic/Original.jpg
And here's the code to run. WinSpy supplied is between noted rems
'
And here's what WinSpy code produced: http://www.SwedesDock.com/powerbasic/Winspy.jpg
Pretty cool I thought.
So I thought I'd try it on the something familiar (my DB). Here'w what it looked at: http://www.SwedesDock.com/powerbasic/Original.jpg
And here's the code to run. WinSpy supplied is between noted rems
'
Code:
'PBWIN 9.00 - WinApi 05/2008 - XP Pro SP3 #Compile Exe #Dim All #Include "WIN32API.INC" #Include "COMDLG32.INC" #Include "InitCtrl.inc" 'Had to add these Id Numbers %IDC_LABEL2620 = %WM_User + 100 %IDC_LISTBOX2601 = %WM_User + 100 %IDC_LABEL2660 = %WM_User + 100 %IDC_EDIT2602 = %WM_User + 100 %IDC_EDIT2603 = %WM_User + 100 %IDC_EDIT2604 = %WM_User + 100 %IDC_EDIT2605 = %WM_User + 100 %IDC_EDIT2606 = %WM_User + 100 %IDC_BUTTON2707 = %WM_User + 100 %IDC_EDIT2607 = %WM_User + 100 %IDC_EDIT2608 = %WM_User + 100 %IDC_BUTTON2709 = %WM_User + 100 %IDC_EDIT2609 = %WM_User + 100 %IDC_EDIT2610 = %WM_User + 100 %IDC_EDIT2611 = %WM_User + 100 %IDC_EDIT2612 = %WM_User + 100 %IDC_EDIT2613 = %WM_User + 100 %IDC_EDIT2614 = %WM_User + 100 %IDC_BUTTON900 = %WM_User + 100 %IDC_BUTTON806 = %WM_User + 100 %IDC_BUTTON806 = %WM_User + 100 %IDC_BUTTON804 = %WM_User + 100 %IDC_BUTTON803 = %WM_User + 100 %IDC_BUTTON809 = %WM_User + 100 %IDC_BUTTON810 = %WM_User + 100 %IDC_BUTTON802 = %WM_User + 100 %IDC_BUTTON807 = %WM_User + 100 %IDC_BUTTON801 = %WM_User + 100 %IDC_BUTTON2708 = %WM_User + 100 %IDC_BUTTON2618 = %WM_User + 100 %IDC_BUTTON2619 = %WM_User + 100 Function PBMain ErrClear Local Hdlg As Dword '<<< WinSpy code from here down '<<< WinSpy code from here down '<<< WinSpy code from here down Dialog New 0, " Testing1 " + _ " GHL_Database Version (2.01) by Carolelle Publishing® (®2008) ", , , 678, 431, _ %WS_VISIBLE Or %WS_CLIPSIBLINGS Or %WS_CAPTION Or %WS_SYSMENU Or _ %WS_THICKFRAME Or %WS_MINIMIZEBOX Or %WS_MAXIMIZEBOX Or _ %DS_ABSALIGN Or %DS_3DLOOK Or %DS_NOFAILCREATE Or %DS_SETFONT, _ %WS_EX_CONTROLPARENT Or %WS_EX_WINDOWEDGE To hDlg 'Note: in PB/WIN 7.0 and later, you can also use DIALOG SET ICON hDlg, newicon$ 'For icon from resource, use something like, LoadIcon(hInst, "APP_ICON") Dialog Send hDlg, %WM_SETICON, %ICON_SMALL, LoadIcon(%Null, ByVal %IDI_APPLICATION) Dialog Send hDlg, %WM_SETICON, %ICON_BIG, LoadIcon(%Null, ByVal %IDI_APPLICATION) Control Add Label, hDlg, %IDC_LABEL2620, "Searching", 1, 1, 203, 12, _ %WS_CHILD Or %WS_VISIBLE Control Add ListBox, hDlg, %IDC_LISTBOX2601, , 1, 15, 203, 394, _ %WS_CHILD Or %WS_VISIBLE Or %WS_BORDER Or %LBS_NOTIFY Or _ %LBS_NOINTEGRALHEIGHT Or %LBS_EXTENDEDSEL Control Add Label, hDlg, %IDC_LABEL2660, " ", 1, 406, 203, 12, _ %WS_CHILD Or %WS_VISIBLE Control Add Label, hDlg, -1, "Index ", 213, 6, 50, 11, _ %WS_CHILD Or %WS_VISIBLE Or %SS_RIGHT Control Add TextBox, hDlg, %IDC_EDIT2602, "Affordable Websites", 265, 6, 358, 11, _ %WS_CHILD Or %WS_VISIBLE Or %ES_NOHIDESEL Control Add Label, hDlg, -1, "WholeName ", 213, 20, 50, 11, _ %WS_CHILD Or %WS_VISIBLE Or %SS_RIGHT Control Add TextBox, hDlg, %IDC_EDIT2603, "Smith, Jane", 265, 20, 358, 11, _ %WS_CHILD Or %WS_VISIBLE Or %ES_NOHIDESEL Control Add Label, hDlg, -1, "Address1 ", 213, 34, 50, 11, _ %WS_CHILD Or %WS_VISIBLE Or %SS_RIGHT Control Add TextBox, hDlg, %IDC_EDIT2604, "37 Ardmore Rd 58 Wildwood " + _ "Ave", 265, 34, 358, 11, _ %WS_CHILD Or %WS_VISIBLE Or %ES_NOHIDESEL Control Add Label, hDlg, -1, "Address2 ", 213, 49, 50, 11, _ %WS_CHILD Or %WS_VISIBLE Or %SS_RIGHT Control Add TextBox, hDlg, %IDC_EDIT2605, "", 265, 49, 358, 11, _ %WS_CHILD Or %WS_VISIBLE Or %ES_NOHIDESEL Control Add Label, hDlg, -1, "CityName ", 213, 63, 50, 11, _ %WS_CHILD Or %WS_VISIBLE Or %SS_RIGHT Control Add TextBox, hDlg, %IDC_EDIT2606, "Lavallette, NJ 08735", 265, 63, 358, 11, _ %WS_CHILD Or %WS_VISIBLE Or %ES_NOHIDESEL Control Add Button, hDlg, %IDC_BUTTON2707, "&Phone ", 213, 77, 50, 11 Control Add TextBox, hDlg, %IDC_EDIT2607, "201-652-4569:Andy", 265, 77, 358, 11, _ %WS_CHILD Or %WS_VISIBLE Or %ES_NOHIDESEL Control Add Button, hDlg, %IDC_BUTTON2708, "P&hone ", 213, 91, 50, 11 Control Add TextBox, hDlg, %IDC_EDIT2608, "973-783-7124:Susan", 265, 91, 358, 11, _ %WS_CHILD Or %WS_VISIBLE Or %ES_NOHIDESEL Control Add Button, hDlg, %IDC_BUTTON2709, "Ph&one ", 213, 105, 50, 11 Control Add TextBox, hDlg, %IDC_EDIT2609, "", 265, 105, 358, 11, _ %WS_CHILD Or %WS_VISIBLE Or %ES_NOHIDESEL Control Add Button, hDlg, %IDC_BUTTON2618, "&Email ", 213, 119, 50, 11 Control Add TextBox, hDlg, %IDC_EDIT2610, "[email protected]:Andy", 265, 119, 358, 11, _ %WS_CHILD Or %WS_VISIBLE Or %ES_NOHIDESEL Control Add Button, hDlg, %IDC_BUTTON2619, "UR&L ", 213, 134, 50, 11 Control Add TextBox, hDlg, %IDC_EDIT2611, "[EMAIL="[email protected]"][email protected][/EMAIL]", 265, 134, 358, 11, _ %WS_CHILD Or %WS_VISIBLE Or %ES_NOHIDESEL Control Add Label, hDlg, -1, "Extra ", 213, 148, 50, 11, _ %WS_CHILD Or %WS_VISIBLE Or %SS_RIGHT Control Add TextBox, hDlg, %IDC_EDIT2612, "", 265, 148, 358, 11, _ %WS_CHILD Or %WS_VISIBLE Or %ES_NOHIDESEL Control Add Label, hDlg, -1, "Extra ", 213, 162, 50, 11, _ %WS_CHILD Or %WS_VISIBLE Or %SS_RIGHT Control Add TextBox, hDlg, %IDC_EDIT2613, "", 265, 162, 358, 11, _ %WS_CHILD Or %WS_VISIBLE Or %ES_NOHIDESEL Control Add TextBox, hDlg, %IDC_EDIT2614, "This Field can hold 10,000 " + _ "characters." + $CrLf + "More than 5 single spaced typed pages." + $CrLf + "" + $CrLf + "In Courier Font, " + _ "numbers can be arranged" + $CrLf + " in columns " + _ "that line up like this:" + $CrLf + " " + _ " 12 34 567 89 10" + $CrLf + " " + _ " 2 4 7 8 15" + $CrLf + " " + _ " 12 34 567 89 10" + $CrLf + " " + _ " - 34 - 89 99", 213, 176, 461, 233, _ %WS_CHILD Or %WS_VISIBLE Or %WS_VSCROLL Or %ES_MULTILINE Or _ %ES_WANTRETURN Or %ES_NOHIDESEL Or %ES_AUTOVSCROLL Control Add Button, hDlg, %IDC_BUTTON801, "&Add", 625, 6, 50, 15 Control Add Button, hDlg, %IDC_BUTTON807, "Sa&ve", 625, 25, 50, 15 Control Add Button, hDlg, %IDC_BUTTON802, "&Delete", 625, 44, 50, 15 Control Add Button, hDlg, %IDC_BUTTON810, "Ne&w", 625, 63, 50, 15 Control Add Button, hDlg, %IDC_BUTTON809, "&Recover", 625, 82, 50, 15 Control Add Button, hDlg, %IDC_BUTTON803, "&Search", 625, 102, 50, 15 Control Add Button, hDlg, %IDC_BUTTON804, "&Next Search", 625, 121, 50, 15 Control Add Button, hDlg, %IDC_BUTTON806, "&Clipper", 625, 140, 50, 15 Control Add Button, hDlg, %IDC_BUTTON900, "&Quit", 625, 159, 50, 15 '<<< WinSpy code to here '<<< WinSpy code to here Dialog Show Modal hDlg '<<<< ? "testing" End Function 'Applikation beenden '
Pretty cool I thought.
Comment