Create event on Browse.Refresh

Source code related resources

Moderator: Rathinagiri

Post Reply
User avatar
mol
Posts: 3718
Joined: Thu Sep 11, 2008 5:31 am
Location: Myszków, Poland
Contact:

Create event on Browse.Refresh

Post by mol »

Is it the way to create event on Browse.REFRESH?
I want to test where my application loose time and unnecessary refresh data (it looks like blinking).
I've read whole code and can't find solution.
regards, Marek
User avatar
mol
Posts: 3718
Joined: Thu Sep 11, 2008 5:31 am
Location: Myszków, Poland
Contact:

Re: Create event on Browse.Refresh

Post by mol »

I've found simple solution.
I've modified source file h_browse.prg, function _BrowseRefresh and I've added lines:

Code: Select all

  if valtype("Browse_Refresh_Event") == "C"
		&Browse_Refresh_Event
 endif
In my app I've declared variable Browse_Refresh_Event as char with assigned tracking function:

Code: Select all

private Browse_Refresh_Event := "BROWSE_WhereAmI()"
and BROWSE_WhereAmI() function:

Code: Select all

function BROWSE_WhereAmI
   local cTrack := ""
   local i := 2
	while ( !Empty(ProcName(i)) )
		cTrack+= ProcName(i) + "(" + NTRIM(ProcLine(i)) + ")"+EOL
		i++
	end
	msgdebug(cTrack)
return

Maybe it will be useful for sb.

Regards, Marek
Javier Tovar
Posts: 1275
Joined: Tue Sep 03, 2013 4:22 am
Location: Tecámac, México

Re: Create event on Browse.Refresh

Post by Javier Tovar »

Hola Mol,

Si podrías subir el archivo completo de h_browse.prg, y un ejemplo para su aplicación?

Saludos
Post Reply