Hola :
En el control browse muestro el estado de la base a medida que agrego items . Necesito aprovechar toda la ventana del browse ya que el scroll solo muestra la mitad de la pantalla del browse . Este efecto en el ejemplo comienza a partir del ingreso del 6 item .
Es posible realizar esto ?
Saludos .
Mario Mansilla
Hi
In the Browser displays the state control of the base as you add items. I need to take full advantage of the browser window as the scroll only shows half the screen browse. This effect in the example starts from receipt of item 6.
It is possible to do this?
Greetings.
Mario Mansilla
Browse Scroll
Moderator: Rathinagiri
-
- Posts: 269
- Joined: Wed Aug 13, 2008 2:35 pm
- Location: Córdoba - Argentina
Browse Scroll
- Attachments
-
- Browse.rar
- (664.44 KiB) Downloaded 342 times
Re: Browse Scroll
Hi Mario,Mario Mansilla wrote: Hi
In the Browser displays the state control of the base as you add items. I need to take full advantage of the browser window as the scroll only shows half the screen browse. This effect in the example starts from receipt of item 6.
It is possible to do this?
Greetings.
Mario Mansilla
Please be so kind to try the updated sample below:
Code: Select all
#include <hmg.ch>
Function Main
SET NAVIGATION EXTENDED
SET CENTURY ON
SET BROWSESYNC ON
Load Window Main
Main.Center
Main.Activate
Return
*-----------------------
Static Procedure Abrir_Bases()
*-----------------------
*--
* Abro Bases
*--
Use Datos Exclusive New
Go Top
Zap
Main.Browse_1.Value := Datos->(Recno())
Return
*-----------------------
Static Procedure Cerrar_Bases()
*-----------------------
Close Datos
Return
*-----------------------
Static Procedure Agregar
*-----------------------
Local Contador := Datos->(Recc()) + 1
Static nCode := 1
Datos->(Dbappend())
Replace Cantidad With nCode++
Replace Nombre With "Articulo " + Strzero(Contador,4)
Replace Unitario With 1.00
Replace Importe With 1.00
INSERT_CTRL_END()
Main.Browse_1.Refresh
Main.Browse_1.Value := Recno()
Main.Browse_1.Setfocus
Return
#pragma BEGINDUMP
#include <windows.h>
#include "hbapi.h"
HB_FUNC( INSERT_CTRL_END )
{
keybd_event
(
VK_CONTROL, // virtual-key code
0, // hardware scan code
0, // flags specifying various function options
0 // additional data associated with keystroke
);
keybd_event
(
VK_END, // virtual-key code
0, // hardware scan code
0, // flags specifying various function options
0 // additional data associated with keystroke
);
keybd_event
(
VK_CONTROL, // virtual-key code
0, // hardware scan code
KEYEVENTF_KEYUP, // flags specifying various function options
0 // additional data associated with keystroke
);
}
#pragma ENDDUMP
Kind Regards,
Grigory Filatov
"Everything should be made as simple as possible, but no simpler." Albert Einstein
Grigory Filatov
"Everything should be made as simple as possible, but no simpler." Albert Einstein
-
- Posts: 269
- Joined: Wed Aug 13, 2008 2:35 pm
- Location: Córdoba - Argentina
Re: Browse Scroll
Hi Grigory :
funciona perfecto , muchas gracias
works perfect, thank you very much
Saludos.
Mario Mansilla
funciona perfecto , muchas gracias
works perfect, thank you very much
Saludos.
Mario Mansilla
Re: Browse Scroll
working fine!
Thanks for this lesson, Grigori
Thanks for this lesson, Grigori
Re: Browse Scroll
Hi Marek,mol wrote:working fine!
Thanks for this lesson, Grigori
There is also the reduced version of this sample without using a C-level function.
Code: Select all
#include <hmg.ch>
Function Main
SET NAVIGATION EXTENDED
SET CENTURY ON
SET BROWSESYNC ON
Load Window Main
Main.Center
Main.Activate
Return Nil
*-----------------------
Static Procedure Abrir_Bases()
*-----------------------
Use Datos Exclusive New
Zap
Return
*-----------------------
Static Procedure Cerrar_Bases()
*-----------------------
Close Datos
Return
*-----------------------
Static Procedure Agregar
*-----------------------
Local Contador := Datos->(Recc()) + 1
Datos->(Dbappend())
Replace Cantidad With Contador
Replace Nombre With "Articulo " + Strzero(Contador,4)
Replace Unitario With Contador
Replace Importe With Contador
_PushKey( VK_END )
Main.Browse_1.Value := Recno()
Main.Browse_1.Setfocus
Return
Kind Regards,
Grigory Filatov
"Everything should be made as simple as possible, but no simpler." Albert Einstein
Grigory Filatov
"Everything should be made as simple as possible, but no simpler." Albert Einstein