AGLog.Write(AGLog.INFO, "start.aspx.cs: Checking version... :" + Session["AvantGo-Version"]);
// Require client version 5 or better
int RequiredMajorVersion = 5;
string version = (string)Session["AvantGo-Version"];
if(version != null) {
string [] vers = version.Split(''.'');
if(vers.Length != 3 ||
System.Convert.ToInt16(vers[0]) < RequiredMajorVersion) {
AGLog.Write(AGLog.WARN,
"start.aspx.cs: Invalid client version: " + version
+ "Device Type: " +
(string)Session[ "MS_DEVICE_TYPE" ]);
AGSyncLog.UpdateSyncStatus(syncId,"3000",
"Invalid Client Version",
transactionsQueued,
transactionsProcessed,
transactionsFailed);
Response.Redirect( Request.ApplicationPath +
"/avantgo/invalidclientpage/invalidclientpage.aspx");
return;
}
}
AGLog.Write(AGLog.INFO, "start.aspx.cs: Done checking version...");
} |
|