Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Ok, work this one out!!
Message
De
19/02/2002 11:56:26
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00621981
Message ID:
00622009
Vues:
34
OK, BTW it's intermittent !!!
LOCAL lcOrder, llDescending
llDescending = (this.opgOrder.Value = 2)
lcOrder = UPPER(ALLTRIM(this.cboOrder.Value)) + " "

*Check if Client Surname/Forename is picked
DO CASE
	*Surname, then Forename
	CASE lcOrder = "SURFOR "
		lcOrder = "Cl_Sname " + IIF(llDescending, "DESC,", ",") + "Cl_Fname "
	*Forename, then Surname
	CASE lcOrder = "FORSUR "
		lcOrder = "Cl_Fname " + IIF(llDescending, "DESC,", ",") + "Cl_Sname "
	OTHERWISE
		lcOrder = lcOrder + IIF(llDescending, "DESC", "")
ENDCASE

*Setup RowSource
this.pgfPageFrame.Page1.lstIntray.RowSource = ;
	"SELECT Ml_DateTime,ALLTRIM(Cl_Fname)+' '+ALLTRIM(Cl_Sname), "+;
	"Ml_Content,Ml_Ref "+;
	"FROM Ccmsmail "+;
	"LEFT JOIN Client "+;
	"ON Ccmsmail.Cl_Ref = Client.Cl_Ref "+;
	"WHERE Ml_To = gu_User "+;
	"AND !Ml_Sent "+;
	"ORDER BY " + lcOrder + ;
	" INTO CURSOR recInTray"
this.pgfPageFrame.Page2.lstOutTray.RowSource = ;
	"SELECT Ml_DateTime,ALLTRIM(Cl_Fname)+' '+ALLTRIM(Cl_Sname), "+;
	"Ml_Content,Ml_Ref "+;
	"FROM Ccmsmail "+;
	"LEFT JOIN Client "+;
	"ON Ccmsmail.Cl_Ref = Client.Cl_Ref "+;
	"WHERE Ml_From = gu_User "+;
	"AND Ml_Sent "+;
	"ORDER BY " + lcOrder + ;
	" INTO CURSOR recOutTray"
	
*Refresh
this.RefreshLists()
And here is refreshlists:
WITH thisForm.pgfPageFrame
	.Page1.lstInTray.Requery()
	.Page2.lstOutTray.Requery()
ENDWITH

*Run InteractiveChange on the currently active list
DO CASE
	CASE this.pgfPageFrame.ActivePage = 1
		this.pgfPageFrame.Page1.lstInTray.InteractiveChange()
	CASE this.pgfPageFrame.ActivePage = 2
		this.pgfPageFrame.Page2.lstOutTray.InteractiveChange()
ENDCASE
		
thisForm.Refresh()
Kev
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform