Browse of my ADO Class

Re: Browse of my ADO Class

Postby Antonio Linares » Wed Dec 18, 2024 6:42 pm

Dear José,

Many thanks for your feedback!

Could you provide us an example PRG to reproduce the error ? many thanks
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42198
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Browse of my ADO Class

Postby JoséQuintas » Thu Dec 19, 2024 4:20 pm

A sample near my use.
In sample I do not change errorsys and debug.
Not sure if sample was to show about fw 24.10 or to show about resource.

allowdup.bat is to accept duplicated functions
dummy.prg is for functions not available on mingw
fivewin.hbc need adjust about your fivewin paths

On each get of each window, F9 call browse.
if click on browse area, changing from one to another window, error about resource.
Sometimes not on first clicks.

sample with prg,ico,rc,hbp,hbc,bat
http://www.jpatecnologia.com.br/arquivos/testmt.zip
JoséQuintas
 
Posts: 44
Joined: Tue Feb 09, 2021 4:20 pm

Re: Browse of my ADO Class

Postby karinha » Thu Dec 19, 2024 5:33 pm

Mister Quintas, você pode disponibilizar completo com o .EXE, por gentileza?

Mister Quintas, can you make it available complete with the .EXE, please?

Señor Quintas, ¿puede ponerlo a disposición completo con el .EXE, por favor?

Obrigado, gracias, tks.

Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7872
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: Browse of my ADO Class

Postby JoséQuintas » Thu Dec 19, 2024 8:45 pm

Mesmo link, adicionado EXE
Lembrando que é com bug de resource.

Same link, added EXE
Remember it is with resource bug.

http://www.jpatecnologia.com.br/arquivos/testmt.zip
JoséQuintas
 
Posts: 44
Joined: Tue Feb 09, 2021 4:20 pm

Re: Browse of my ADO Class

Postby karinha » Fri Dec 20, 2024 1:33 pm

Mister Quintas, se eu entendi, a vantagem aqui, é que se eu tenho uma aplicação MODO CONSOLE, eu posso acionar um módulo FOR WINDOWS direto do meu programa MODO COSOLE, é isso? Sinceramte... Não vi vantagem nenhuma.

Mister Quintas, if I understand, the advantage here is that if I have a MODO CONSOLE application, I can activate a FOR WINDOWS module directly from my MODO COSOLE program, is that it? Honestly... I didn't see any advantage.

Señor Quintas, si tengo entendido, la ventaja aquí es que si tengo una aplicación MODO CONSOLE, puedo activar un módulo FOR WINDOWS directamente desde mi programa MODO COSOLE, ¿es así? Sinceramente... no vi ninguna ventaja.

Code: Select all  Expand view  RUN

REQUEST HB_CODEPAGE_PTISO

#include "inkey.ch"

PROCEDURE Main()

   Set( _SET_CODEPAGE, "PTISO" )

   fw_SetTruePixel( .T. )

   RunModuleAsThread( { || test_Module() } )
   RunModuleAsThread( { || test_Module() } )

   hb_ThreadWaitForAll()

RETURN

FUNCTION Test_Module()

   LOCAL aCodeList := Array(5), GetList := {}, nCode

   Afill( aCodeList, 0 )

   // aqui eu aciono uma TELA DO FIVEWIN FOR WINDOWS.
   SET KEY K_F9 TO test_browse

   @ 0, 0 SAY ""

   FOR EACH nCode IN aCodeList
      @ Row() + 1, 1 SAY "Code:" GET nCode PICTURE "99999"
   NEXT

   READ

RETURN Nil

PROCEDURE HB_GTSYS

   REQUEST HB_GT_WVG_DEFAULT

RETURN
 


Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7872
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: Browse of my ADO Class

Postby JoséQuintas » Fri Dec 20, 2024 2:28 pm

Tenho um aplicativo com centenas de dialogs.
Posso alterar pra fivewin qualquer dialog a qualquer momento.
Não vê vantagem nisso ?
Se fosse só essa vantagem, ela já é muito útil.

I have an application with thousands of dialogs.
I can change any dialog to fivewin at any time.
Do you not see advantage on this ?
If this was the only advantage, it already is usefull.
JoséQuintas
 
Posts: 44
Joined: Tue Feb 09, 2021 4:20 pm

Re: Browse of my ADO Class

Postby karinha » Fri Dec 20, 2024 3:20 pm

JoséQuintas wrote:Tenho um aplicativo com centenas de dialogs.
Posso alterar pra fivewin qualquer dialog a qualquer momento.
Não vê vantagem nisso ?
Se fosse só essa vantagem, ela já é muito útil.

I have an application with thousands of dialogs.
I can change any dialog to fivewin at any time.
Do you not see advantage on this ?
If this was the only advantage, it already is usefull.


Tenho um aplicativo com centenas de dialogs.


I can't discuss this with you. When you have a powerful DEMO in FIVEWIN, please post it so I can understand the functionality/usefulness of this command: RunModuleAsThread( { || test_Module() } )

No puedo discutir esto contigo. Cuando tenga una DEMOSTRACIÓN potente en FIVEWIN, publíquela para que pueda comprender la funcionalidad/utilidad de este comando: RunModuleAsThread( { || test_Module() } )

Explique: ¿Qué gano al usar este comando?

Explain: What do I gain by using this command?

Gracias, tks.

Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7872
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: Browse of my ADO Class

Postby JoséQuintas » Sat Dec 21, 2024 8:52 pm

3 new calls:

Code: Select all  Expand view  RUN

PROCEDURE Main()

   Set( _SET_CODEPAGE, "PTISO" )
   SET EXCLUSIVE OFF
   fw_SetTruePixel( .T. )
   RunModuleAsThread( { || test_Module() } )
   RunModuleAsThread( { || test_Module() } )
   RunModuleAsThread( { || Test_MBrowse() }, .F. )
   RunModuleAsThread( { || Test_MBrowse() }, .F. )
   RunModuleAsThread( { || Test_MBrowse() }, .F. )
   hb_ThreadWaitForAll()

   RETURN
 


To this fivewin module

Code: Select all  Expand view  RUN

#include "fivewin.ch"

PROCEDURE Test_MBrowse

   USE dbproduct
   BROWSE()
   CLOSE DATABASES

   RETURN
 


Why this function:
Code: Select all  Expand view  RUN

FUNCTION RunModuleAsThread( bCode, lIsWVG )

   LOCAL pThread

   pThread := hb_ThreadStart( { || RunModule( bCode, lIsWVG ) } )

   RETURN pThread
 


Because on another use I need the thread number.

Why this function ?
Code: Select all  Expand view  RUN

FUNCTION RunModule( bCode, lIsWVG )

   hb_Default( @lIsWVG, .T. )
   hb_gtReload( "WVG" )
   IF lIsWVG
      SetMode(25,80)
      CLS
   ENDIF
   Eval( bCode )

   RETURN Nil
 


Because fivewin make changes on current gtwvg window, then I create a fake gtwvg window to be changed by fivewin.
Some libraries can lock previous window, (like dialog modal), fake gtwvg window can be locked without problems.
If hb_gtReload() is not needed, it is ignored, I do not need to add IFs.
If module is gtwvg, it will have a visible window (SetMode() and CLS).

Attention on this part on module:
Code: Select all  Expand view  RUN

CLOSE DATABASES
 


Each thread/dialog have it's own files.
CLOSE DATABASES will close files used on thread only.

zip is updated, added dbf and module, and EXE is signed, to try prevent antivírus block.
http://www.jpatecnologia.com.br/arquivos/testmt.zip

Remember: my fivewin use is together with GTWVG, it is not the same for those using fivewin only.

Image
JoséQuintas
 
Posts: 44
Joined: Tue Feb 09, 2021 4:20 pm

Re: Browse of my ADO Class

Postby karinha » Sun Dec 22, 2024 3:26 pm

GTWVG?? What is that? I have no idea how to compile this thing. It doesn't even make sense to me, knowing how to program in PURE FIVEWIN, why would I mix something prehistoric with something as modern and powerful as FIVEWIN? I'm sorry, I don't use CONSOLE MODE under any circumstances.

GTWVG?? ¿Qué es eso? No tengo idea de cómo compilar esto. Ni siquiera tiene sentido para mí, saber programar en PURE FIVEWIN, ¿por qué mezclaría algo prehistórico con algo tan moderno y poderoso como FIVEWIN? Lo siento, no uso el MODO CONSOLA bajo ninguna circunstancia.

I LOVE FIVEWIN FOREVER!

Gracias, tks.

Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7872
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: Browse of my ADO Class

Postby JoséQuintas » Sun Dec 22, 2024 9:26 pm

karinha wrote:GTWVG?? What is that? I have no idea how to compile this thing. It doesn't even make sense to me, knowing how to program in PURE FIVEWIN, why would I mix something prehistoric with something as modern and powerful as FIVEWIN? I'm sorry, I don't use CONSOLE MODE under any circumstances.


GTWVG uses API Windows in same way as fivewin.
GTWVG uses classes in same way as fivewin.
Is API Windows prehistoric ? Is fivewin prehistoric ?

I do not understand why you post anything like this.
Do you not want new fivewin users ?
JoséQuintas
 
Posts: 44
Joined: Tue Feb 09, 2021 4:20 pm

Re: Browse of my ADO Class

Postby JoséQuintas » Mon Dec 23, 2024 1:02 am

karinha wrote:I can't discuss this with you. When you have a powerful DEMO in FIVEWIN,


Do you understand that this is a FIVEWIN module ?

Code: Select all  Expand view  RUN

#include "fivewin.ch"

PROCEDURE Test_MBrowse

   USE dbproduct
   BROWSE()
   CLOSE DATABASES

   RETURN
 


check fivewin\samples\browse.prg

It is a sample, a simple sample.
Use your imagination for several files, validation and others.
Once you are a long time fivewin user, try to do the same without multithread.
JoséQuintas
 
Posts: 44
Joined: Tue Feb 09, 2021 4:20 pm

Previous

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot], Horizon and 26 guests