-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathQUERYIT.FRM
2368 lines (1879 loc) · 74.6 KB
/
QUERYIT.FRM
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
VERSION 5.00
Object = "{6B7E6392-850A-101B-AFC0-4210102A8DA7}#1.3#0"; "COMCTL32.OCX"
Object = "{5EB28C2E-92F5-11D5-BD59-0000E82185CB}#1.0#0"; "XSYSTRAY.OCX"
Begin VB.MDIForm frmMain
BackColor = &H8000000C&
Caption = "Easy Query !"
ClientHeight = 6120
ClientLeft = 1800
ClientTop = 1920
ClientWidth = 8715
Icon = "QueryIt.frx":0000
LinkTopic = "MDIForm1"
WindowState = 2 'Maximized
Begin ComctlLib.Toolbar Toolbar
Align = 1 'Align Top
Height = 465
Left = 0
TabIndex = 1
Top = 0
Width = 8715
_ExtentX = 15372
_ExtentY = 820
ButtonWidth = 688
ButtonHeight = 661
AllowCustomize = 0 'False
Appearance = 1
ImageList = "imgList"
_Version = 327682
BeginProperty Buttons {0713E452-850A-101B-AFC0-4210102A8DA7}
NumButtons = 27
BeginProperty Button1 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = "cmdConectar"
Object.ToolTipText = "Conecta hacia fuente de datos"
Object.Tag = ""
ImageIndex = 19
EndProperty
BeginProperty Button2 {0713F354-850A-101B-AFC0-4210102A8DA7}
Enabled = 0 'False
Key = "cmdDesconectar"
Object.ToolTipText = "Desconecta una conexión previa"
Object.Tag = ""
ImageIndex = 20
Object.Width = 1e-4
EndProperty
BeginProperty Button3 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = ""
Object.Tag = ""
Style = 3
MixedState = -1 'True
EndProperty
BeginProperty Button4 {0713F354-850A-101B-AFC0-4210102A8DA7}
Enabled = 0 'False
Key = "cmdIniTrx"
Object.ToolTipText = "Iniciar Transacción"
Object.Tag = ""
ImageIndex = 11
EndProperty
BeginProperty Button5 {0713F354-850A-101B-AFC0-4210102A8DA7}
Enabled = 0 'False
Key = "cmdFinTrx"
Object.ToolTipText = "Finalizar Transacción"
Object.Tag = ""
ImageIndex = 12
EndProperty
BeginProperty Button6 {0713F354-850A-101B-AFC0-4210102A8DA7}
Enabled = 0 'False
Key = "cmdRollTrx"
Object.ToolTipText = "Cancelar Transaccion"
Object.Tag = ""
ImageIndex = 13
EndProperty
BeginProperty Button7 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = ""
Object.Tag = ""
Style = 3
MixedState = -1 'True
EndProperty
BeginProperty Button8 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = "cmdNuevo"
Object.ToolTipText = "Crea una nueva hoja de consulta"
Object.Tag = ""
ImageIndex = 5
EndProperty
BeginProperty Button9 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = "cmdEliminar"
Object.ToolTipText = "Elimina una hoja de consulta"
Object.Tag = ""
ImageIndex = 18
EndProperty
BeginProperty Button10 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = "cmdLimpiar"
Object.ToolTipText = "Limpia toda la consulta"
Object.Tag = ""
ImageIndex = 8
EndProperty
BeginProperty Button11 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = ""
Object.Tag = ""
Style = 3
MixedState = -1 'True
EndProperty
BeginProperty Button12 {0713F354-850A-101B-AFC0-4210102A8DA7}
Enabled = 0 'False
Key = "cmdAscendente"
Object.ToolTipText = "Ordenar columna ascendente"
Object.Tag = ""
ImageIndex = 21
EndProperty
BeginProperty Button13 {0713F354-850A-101B-AFC0-4210102A8DA7}
Enabled = 0 'False
Key = "cmdDescendente"
Object.ToolTipText = "Ordenar columna descendente"
Object.Tag = ""
ImageIndex = 22
EndProperty
BeginProperty Button14 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = ""
Object.Tag = ""
Style = 3
MixedState = -1 'True
EndProperty
BeginProperty Button15 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = "cmdAbrir"
Object.ToolTipText = "Abre un archivo sql"
Object.Tag = ""
ImageIndex = 9
EndProperty
BeginProperty Button16 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = "cmdGrabar"
Object.ToolTipText = "Graba el contenido de hoja de consulta"
Object.Tag = ""
ImageIndex = 6
EndProperty
BeginProperty Button17 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = "cmdImprimir"
Object.ToolTipText = "Imprime el sql activo"
Object.Tag = ""
ImageIndex = 10
EndProperty
BeginProperty Button18 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = ""
Object.Tag = ""
Style = 3
MixedState = -1 'True
EndProperty
BeginProperty Button19 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = "cmdCopiar"
Object.ToolTipText = "Copia el contenido al portapapeles"
Object.Tag = ""
ImageIndex = 2
EndProperty
BeginProperty Button20 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = "cmdCortar"
Object.ToolTipText = "Corta el contenido al portapapeles"
Object.Tag = ""
ImageIndex = 3
EndProperty
BeginProperty Button21 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = "cmdPegar"
Object.ToolTipText = "Pega el contenido del portapapeles "
Object.Tag = ""
ImageIndex = 4
EndProperty
BeginProperty Button22 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = "cmdUndo"
Object.ToolTipText = "Deshacer cambios realizados"
Object.Tag = ""
ImageIndex = 23
EndProperty
BeginProperty Button23 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = ""
Object.Tag = ""
Style = 3
MixedState = -1 'True
EndProperty
BeginProperty Button24 {0713F354-850A-101B-AFC0-4210102A8DA7}
Enabled = 0 'False
Key = "cmdBuscar"
Object.ToolTipText = "Ejecutar sentencia SQL ..."
Object.Tag = ""
ImageIndex = 30
EndProperty
BeginProperty Button25 {0713F354-850A-101B-AFC0-4210102A8DA7}
Enabled = 0 'False
Key = "cmdDetener"
Object.ToolTipText = "Detener ejecución sentencia SQL ..."
Object.Tag = ""
ImageIndex = 14
EndProperty
BeginProperty Button26 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = ""
Object.Tag = ""
Style = 3
MixedState = -1 'True
EndProperty
BeginProperty Button27 {0713F354-850A-101B-AFC0-4210102A8DA7}
Key = "cmdSalir"
Object.ToolTipText = "Sale de Easy Query!"
Object.Tag = ""
ImageIndex = 7
EndProperty
EndProperty
End
Begin VB.PictureBox Picture1
Align = 1 'Align Top
BeginProperty Font
Name = "Tahoma"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 1095
Left = 0
ScaleHeight = 1035
ScaleWidth = 8655
TabIndex = 2
Top = 465
Visible = 0 'False
Width = 8715
Begin VB.PictureBox picResource
AutoRedraw = -1 'True
AutoSize = -1 'True
BorderStyle = 0 'None
Height = 150
Index = 3
Left = 420
Picture = "QueryIt.frx":08CA
ScaleHeight = 150
ScaleWidth = 1050
TabIndex = 4
TabStop = 0 'False
Top = 780
Visible = 0 'False
Width = 1050
End
Begin VB.PictureBox picResource
AutoRedraw = -1 'True
AutoSize = -1 'True
BorderStyle = 0 'None
Height = 720
Index = 2
Left = 0
Picture = "QueryIt.frx":0D03
ScaleHeight = 720
ScaleWidth = 9180
TabIndex = 3
TabStop = 0 'False
Top = 0
Visible = 0 'False
Width = 9180
End
End
Begin SysTray.XSystray cSystray1
Left = 4095
Top = 2805
_ExtentX = 900
_ExtentY = 900
InTray = 0 'False
TrayIcon = "QueryIt.frx":25A3
TrayTip = "SysTray Control."
End
Begin ComctlLib.StatusBar staBar
Align = 2 'Align Bottom
Height = 285
Left = 0
TabIndex = 0
Top = 5835
Width = 8715
_ExtentX = 15372
_ExtentY = 503
SimpleText = ""
_Version = 327682
BeginProperty Panels {0713E89E-850A-101B-AFC0-4210102A8DA7}
NumPanels = 2
BeginProperty Panel1 {0713E89F-850A-101B-AFC0-4210102A8DA7}
AutoSize = 1
Object.Width = 12383
Text = "Easy Query ! Chile 2001"
TextSave = "Easy Query ! Chile 2001"
Key = ""
Object.Tag = ""
EndProperty
BeginProperty Panel2 {0713E89F-850A-101B-AFC0-4210102A8DA7}
Style = 5
TextSave = "10:12 a.m."
Key = ""
Object.Tag = ""
EndProperty
EndProperty
End
Begin ComctlLib.ImageList imgList
Left = 3495
Top = 615
_ExtentX = 1005
_ExtentY = 1005
BackColor = -2147483643
ImageWidth = 19
ImageHeight = 19
MaskColor = 12632256
_Version = 327682
BeginProperty Images {0713E8C2-850A-101B-AFC0-4210102A8DA7}
NumListImages = 30
BeginProperty ListImage1 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":28BD
Key = ""
Object.Tag = "B&uscar"
EndProperty
BeginProperty ListImage2 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":2A33
Key = ""
Object.Tag = "&Copiar"
EndProperty
BeginProperty ListImage3 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":2BA9
Key = ""
Object.Tag = "C&ortar"
EndProperty
BeginProperty ListImage4 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":2D1F
Key = ""
Object.Tag = "&Pegar"
EndProperty
BeginProperty ListImage5 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":2E95
Key = ""
Object.Tag = "&Nuevo"
EndProperty
BeginProperty ListImage6 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":300B
Key = ""
Object.Tag = "&Guardar"
EndProperty
BeginProperty ListImage7 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":3181
Key = ""
Object.Tag = "&Salir"
EndProperty
BeginProperty ListImage8 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":32F7
Key = ""
Object.Tag = "&Limpiar"
EndProperty
BeginProperty ListImage9 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":346D
Key = ""
Object.Tag = "&Abrir"
EndProperty
BeginProperty ListImage10 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":357F
Key = ""
Object.Tag = "&Imprimir"
EndProperty
BeginProperty ListImage11 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":36F5
Key = ""
EndProperty
BeginProperty ListImage12 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":3A47
Key = ""
EndProperty
BeginProperty ListImage13 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":3D99
Key = ""
EndProperty
BeginProperty ListImage14 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":40EB
Key = "cmdBorrar"
EndProperty
BeginProperty ListImage15 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":41FD
Key = ""
EndProperty
BeginProperty ListImage16 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":454F
Key = ""
EndProperty
BeginProperty ListImage17 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":48A1
Key = ""
Object.Tag = "&Skins"
EndProperty
BeginProperty ListImage18 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":4BBB
Key = ""
Object.Tag = "&Eliminar"
EndProperty
BeginProperty ListImage19 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":4ED5
Key = ""
Object.Tag = "&Conectar"
EndProperty
BeginProperty ListImage20 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":51EF
Key = ""
Object.Tag = "&Desconectar"
EndProperty
BeginProperty ListImage21 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":5509
Key = ""
EndProperty
BeginProperty ListImage22 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":561B
Key = ""
EndProperty
BeginProperty ListImage23 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":572D
Key = ""
Object.Tag = "&Deshacer"
EndProperty
BeginProperty ListImage24 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":583F
Key = ""
EndProperty
BeginProperty ListImage25 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":5A19
Key = ""
EndProperty
BeginProperty ListImage26 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":5BF3
Key = ""
EndProperty
BeginProperty ListImage27 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":5DCD
Key = ""
EndProperty
BeginProperty ListImage28 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":60E7
Key = ""
EndProperty
BeginProperty ListImage29 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":62C1
Key = ""
EndProperty
BeginProperty ListImage30 {0713E8C3-850A-101B-AFC0-4210102A8DA7}
Picture = "QueryIt.frx":649B
Key = ""
EndProperty
EndProperty
End
Begin VB.Menu mnuArchivox
Caption = "&Archivo"
Begin VB.Menu mnuQuery_Conectar
Caption = "&Conectar"
End
Begin VB.Menu mnuQuery_Desconectar
Caption = "&Desconectar"
End
Begin VB.Menu mnuQuery_Sep99
Caption = "-"
End
Begin VB.Menu mnuQuery_Nuevahoja
Caption = "&Nuevo formulario de consultas"
Shortcut = ^N
End
Begin VB.Menu mnuQuery_EliminarHoja
Caption = "&Eliminar formulario de consultas"
Shortcut = ^D
End
Begin VB.Menu mnuQuery_sep2
Caption = "-"
End
Begin VB.Menu mnuQuery_AbrirconsultaSQL
Caption = "&Abrir consulta SQL"
Shortcut = ^O
End
Begin VB.Menu mnuQuery_GuardarSQL
Caption = "&Guardar SQL"
Shortcut = ^G
End
Begin VB.Menu mnuQuery_sep3
Caption = "-"
End
Begin VB.Menu mnuQuery_ConfigImpresora
Caption = "&Configurar Página"
End
Begin VB.Menu mnuQuery_ImprimirSQL
Caption = "&Imprimir SQL"
Shortcut = ^P
End
Begin VB.Menu mnuQuery_sep4
Caption = "-"
End
Begin VB.Menu mnuQuery_Salir
Caption = "&Salir"
End
End
Begin VB.Menu mnuEdicion
Caption = "&Edición"
Begin VB.Menu mnuEdicion_Deshacer
Caption = "&Deshacer"
Shortcut = ^Q
End
Begin VB.Menu mnuEdicion_Copiar
Caption = "&Copiar"
Shortcut = ^C
End
Begin VB.Menu mnuEdicion_Pegar
Caption = "&Pegar"
Shortcut = ^V
End
Begin VB.Menu mnuEdicion_Cortar
Caption = "C&ortar"
Shortcut = ^X
End
Begin VB.Menu mnuEdicion_Borrar
Caption = "&Borrar"
Shortcut = ^B
End
Begin VB.Menu mnuEdicion_sep1
Caption = "-"
End
Begin VB.Menu mnuEdicion_SeleccionarTodo
Caption = "&Seleccionar todo ..."
Shortcut = ^S
End
Begin VB.Menu mnuEdicion_sep2
Caption = "-"
End
Begin VB.Menu mnuEdicion_Buscar
Caption = "B&uscar"
Shortcut = ^F
End
Begin VB.Menu mnuEdicion_BuscarSiguiente
Caption = "Buscar Si&guiente"
Shortcut = {F3}
End
Begin VB.Menu mnuEdicion_sep3
Caption = "-"
End
Begin VB.Menu mnuEdicion_Reemplazar
Caption = "&Reemplazar"
Shortcut = ^R
End
End
Begin VB.Menu mnuQuery
Caption = "&Query"
Enabled = 0 'False
Begin VB.Menu mnuQuery_CopiarDatos
Caption = "&Copiar registros seleccionados"
Shortcut = {F8}
End
Begin VB.Menu mnuQuery_sep11
Caption = "-"
End
Begin VB.Menu mnuQuery_SeleccionarTodo
Caption = "&Seleccionar todos y copiar"
Shortcut = {F7}
End
Begin VB.Menu mnuQuery_DesSeleccionarTodo
Caption = "&DesSeleccionar todos los registros"
Shortcut = {F9}
End
Begin VB.Menu mnuQuery_sep22
Caption = "-"
End
Begin VB.Menu mnuQuery_Imprimir
Caption = "&Imprimir resultado de la búsqueda"
End
Begin VB.Menu mnuQuery_CopiarHeader
Caption = "Copiar &header de consulta"
End
Begin VB.Menu mnuQuery_EiminarFila
Caption = "&Eliminar fila de consulta"
End
Begin VB.Menu sex1
Caption = "-"
End
Begin VB.Menu mnuQuery_VerTabla
Caption = "&Ver estructura de tabla"
End
Begin VB.Menu mnuQuery_VerTodasTablas
Caption = "Ver todas las &tablas de conexión"
End
Begin VB.Menu sex2
Caption = "-"
End
Begin VB.Menu mnuQuery_ExportarCSV
Caption = "Exportar a .CSV"
End
Begin VB.Menu mnuQuery_ExportarXML
Caption = "Exportar a .XML"
End
Begin VB.Menu mnuQuery_ExportarTXT
Caption = "Exportar a .TXT"
End
Begin VB.Menu mnuQuery_ExportarHTM
Caption = "Exportar a .HTM"
End
Begin VB.Menu mnuQuery_ExportarXLS
Caption = "Exportar a .XLS"
End
Begin VB.Menu mnuQuery_ExportarRTF
Caption = "Exportar a .RTF"
Visible = 0 'False
End
End
Begin VB.Menu mnuArchivo
Caption = "&Archivo"
Visible = 0 'False
Begin VB.Menu mnuArchivo_Restaurar
Caption = "Restaurar"
End
Begin VB.Menu mnuArchivo_Acercade
Caption = "&Acerca de Easy Query ! ..."
End
Begin VB.Menu sep1
Caption = "-"
End
Begin VB.Menu mnuArchivo_Salir
Caption = "&Salir"
End
End
Begin VB.Menu mnuOpciones
Caption = "&Opciones"
Begin VB.Menu mnuOpciones_Configuracion
Caption = "C&onfiguración"
End
Begin VB.Menu mnuOpciones_Sep0
Caption = "-"
End
Begin VB.Menu mnuOpciones_Colores
Caption = "&Colores"
End
Begin VB.Menu mnuOpciones_Skin
Caption = "&Skin"
Enabled = 0 'False
Visible = 0 'False
End
Begin VB.Menu mnuOpciones_Sep1
Caption = "-"
End
Begin VB.Menu mnuOpciones_Browser
Caption = "&Browser de Querys"
End
Begin VB.Menu mnuOpciones_FTexto
Caption = "&Formato de Texto"
End
Begin VB.Menu mnuOpciones_SiempreVisible
Caption = "Siempre &visible"
End
End
Begin VB.Menu mnuVentana
Caption = "&Ventana"
WindowList = -1 'True
Begin VB.Menu mnuVentana_Cascada
Caption = "&Cascada"
End
Begin VB.Menu mnuVentana_Horizontal
Caption = "&Horizontal"
End
Begin VB.Menu mnuVentana_Organizar
Caption = "&Organizar ventanas"
End
End
Begin VB.Menu mnuAyuda
Caption = "A&yuda"
Begin VB.Menu mnuAyuda_Contenido
Caption = "&Contenido"
End
Begin VB.Menu mnuAyuda_Indice
Caption = "&Indice"
End
Begin VB.Menu mnuAyuda_Busqueda
Caption = "&Búsqueda"
End
Begin VB.Menu mnuAyuda_sep1
Caption = "-"
End
Begin VB.Menu mnuAyuda_Web
Caption = "&Easy Query ! en el WEB"
End
Begin VB.Menu mnuAyuda_AcercaDe
Caption = "&Acerca de Easy Query ! ..."
End
End
Begin VB.Menu mnuTablas
Caption = "Tablas"
Visible = 0 'False
Begin VB.Menu mnuTablas_ImprimirCampos
Caption = "Imprimir campos consulta"
End
End
End
Attribute VB_Name = "frmMain"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Public m_Detener As Boolean
Private TrxActiva As Boolean
'Private WithEvents HelpObj As HelpCallBack
Dim IsInFocus As Boolean
Dim xad As Long
Dim Largo As Integer
Private WithEvents xConnection As ADODB.Connection
Attribute xConnection.VB_VarHelpID = -1
'Private rsPaso As New ADODB.Recordset
Private Sub AbreSql()
On Local Error GoTo ErrorAbreSql
Dim cc As New GCommonDialog
Dim Archivo As String
Dim nArchivo As Integer
Dim Sql As String
Dim Glosa As String
Glosa = "Archivos de comandos Sql (*.SQL)|*.SQL|"
Glosa = Glosa & "Archivos de comandos Texto (*.TXT)|*.TXT|"
Glosa = Glosa & "Todos los archivos (*.*)|*.*"
If Not (cc.VBGetOpenFileName(Archivo, , , , , , Glosa, , App.Path, "Abrir archivo ...", "SQL", Me.hwnd)) Then
Exit Sub
End If
If Archivo <> "" Then
nArchivo = FreeFile
Open Archivo For Input As #nArchivo
Sql = Input(LOF(nArchivo), nArchivo)
Close #nArchivo
frmMain.ActiveForm.txtQuery.Text = vbNullString
frmMain.ActiveForm.txtQuery.SelColor = QBColor(1)
frmMain.ActiveForm.txtQuery.Text = Sql
End If
'frmMain.ActiveForm.txtQuery.Visible = False
frmMain.ActiveForm.HayCambios = True
Call frmMain.ActiveForm.FormateaSentencias
'frmMain.ActiveForm.txtQuery.Visible = True
frmMain.ActiveForm.txtQuery.SetFocus
Set cc = Nothing
GoTo SalirAbreSql
ErrorAbreSql:
Resume SalirAbreSql
SalirAbreSql:
Err = 0
End Sub
Private Sub Ascendente()
If frmMain.ActiveForm.griQuery.DataRowCnt > 0 Then
frmMain.ActiveForm.griQuery.Col = 1 'frmMain.ActiveForm.griQuery.ActiveCol
frmMain.ActiveForm.griQuery.Col2 = frmMain.ActiveForm.griQuery.MaxCols
frmMain.ActiveForm.griQuery.Row = 0
frmMain.ActiveForm.griQuery.Row2 = frmMain.ActiveForm.griQuery.DataRowCnt
frmMain.ActiveForm.griQuery.SortBy = 0
frmMain.ActiveForm.griQuery.SortKey(1) = frmMain.ActiveForm.griQuery.ActiveCol
frmMain.ActiveForm.griQuery.SortKeyOrder(1) = 1
frmMain.ActiveForm.griQuery.Action = 25
End If
End Sub
Private Function ChequeaComandoCritico() As Boolean
Dim k As Integer
Dim ret As Boolean
Dim Sql As String
Sql = Trim$(frmMain.ActiveForm.txtQuery.Text)
ret = False
For k = 1 To UBound(Comandos)
If Comandos(k).Activo Then
If UCase$(Comandos(k).Comando) = UCase$(Left$(Sql, Len(Comandos(k).Comando))) Then
ret = True
Exit For
End If
End If
Next k
ChequeaComandoCritico = ret
End Function
Private Sub Descendente()
If frmMain.ActiveForm.griQuery.DataRowCnt > 0 Then
frmMain.ActiveForm.griQuery.Col = 1 'frmMain.ActiveForm.griQuery.ActiveCol
frmMain.ActiveForm.griQuery.Col2 = frmMain.ActiveForm.griQuery.MaxCols
frmMain.ActiveForm.griQuery.Row = 0
frmMain.ActiveForm.griQuery.Row2 = frmMain.ActiveForm.griQuery.DataRowCnt
frmMain.ActiveForm.griQuery.SortBy = 0
frmMain.ActiveForm.griQuery.SortKey(1) = frmMain.ActiveForm.griQuery.ActiveCol
frmMain.ActiveForm.griQuery.SortKeyOrder(1) = 2
frmMain.ActiveForm.griQuery.Action = 25
End If
End Sub
Public Sub EliminarHojaConsulta()
On Local Error Resume Next
Dim fIndex
fIndex = frmMain.ActiveForm.Tag
Unload frmMain.ActiveForm
If Not IsNumeric(fIndex) Then
If mnuOpciones_Browser.Checked Then
frmBrowser.treQuerys.Nodes.Remove fIndex
End If
Else
If mnuOpciones_Browser.Checked Then
frmBrowser.treQuerys.Nodes.Remove "q1"
End If
End If
Err = 0
End Sub
Private Sub FinTRX()
On Local Error Resume Next
Dim ActiveConexion As Integer
Dim ci As ComboItem
Dim msg As String
If frmMain.ActiveForm.imgConexiones.SelectedItem Is Nothing Then Exit Sub
Set ci = frmMain.ActiveForm.imgConexiones.SelectedItem
ActiveConexion = ConexionActiva(ci.Text)
If cState(ActiveConexion).Trx = True Then
msg = "Confirma finalizar transacción activa."
If Confirma(msg) = vbNo Then Exit Sub
cState(ActiveConexion).Trx = False
DBConnection(ActiveConexion).CommitTrans
Toolbar.Buttons("cmdIniTrx").Enabled = True
Toolbar.Buttons("cmdFinTrx").Enabled = False
Toolbar.Buttons("cmdRollTrx").Enabled = False
End If
Set ci = Nothing
Err = 0
End Sub
Public Sub GrabaQuerys()
Dim k As Integer
Dim qR As Integer
Dim Sql As String
Dim ArrayCount As Integer
Dim i As Integer
Dim f As Form
Dim NComandos
'Dim sComando
Dim Activo As String
qR = 1
Call Hourglass(hwnd, True)
Call GrabaIni(C_INI, "skins", "skin", glbPathSkin)
If UBound(Document) = 0 Then Exit Sub
ArrayCount = UBound(Document)
' Cycle through the document array. If one of the
' documents has been deleted, then return that index.
For i = ArrayCount To 1 Step -1
If Not fState(i).Deleted Then
Set f = Document(i)
Sql = f.txtQuery.Text
If Sql <> "" Then
Call f.txtQuery.SaveFile(App.Path & "\query" & qR & ".sql", 1)
qR = qR + 1
End If
Unload f
End If
Next
Call GrabaIni(C_INI, "Querys", "nquerys", CStr(qR - 1))
ReDim Document(0)
Call GrabaIni(C_INI, "ArchivosMDB", "nArchivosMdb", UBound(aArchivosMdb))
For k = 1 To UBound(aArchivosMdb)
Call GrabaIni(C_INI, "ArchivosMDB", "Archivo" & k, aArchivosMdb(k))
Next k
'grabar comandos
'leer comandos criticos
NComandos = UBound(Comandos)
If NComandos > 0 Then
For k = 1 To NComandos
If Comandos(k).Activo Then
Activo = "1"
Else
Activo = "0"
End If
Call GrabaIni(C_INI, "Comandos", "comando" & k, Comandos(k).Comando & "," & Activo)
Next k
End If
Call GrabaIni(C_INI, "Comandos", "ncomandos", NComandos)
Call Hourglass(hwnd, False)
End Sub
Private Sub GrabaSQL()
On Local Error GoTo ErrorGrabaSQL
Dim cc As New GCommonDialog
Dim Archivo As String
Dim nArchivo As Integer
Dim Sql As String
Dim Glosa As String
Glosa = "Archivos de comandos Sql (*.SQL)|*.SQL|"
Glosa = Glosa & "Archivos de comandos Texto (*.TXT)|*.TXT|"
Glosa = Glosa & "Todos los archivos (*.*)|*.*"
If Not (cc.VBGetSaveFileName(Archivo, , , Glosa, , App.Path, "Guardar como ...", "SQL", Me.hwnd)) Then
Exit Sub
End If
If Archivo <> "" Then
nArchivo = FreeFile
Sql = frmMain.ActiveForm.txtQuery.Text
Archivo = Left$(Archivo, Len(Archivo) - 1)
Open Archivo & ".sql" For Output As #nArchivo
Print #nArchivo, Sql
Close #nArchivo
End If
Set cc = Nothing
GoTo SalirGrabaSQL
ErrorGrabaSQL:
Resume SalirGrabaSQL
SalirGrabaSQL:
Err = 0
End Sub
Private Sub Imprimir()
On Local Error GoTo ErrorImprimir
If frmMain.ActiveForm.txtQuery.Text = "" Then Exit Sub
Call Hourglass(hwnd, True)
If Not ShowPrinter(Me) Then GoTo SalirImprimir
Printer.Print frmMain.ActiveForm.txtQuery.Text
GoTo SalirImprimir