%@ Language=VBScript %>
<%OPTION EXPLICIT%>
<%
ConnectRS
'constantes de grandeur
CONST PAGE_W = 800
CONST PAGE_H = 900
CONST VPC = 10.7639
CONST VMC = 10.7639
'variables globales
Dim RS2 : Set RS2 = Server.CreateObject("ADODB.Recordset")
Dim RS3 : Set RS3 = Server.CreateObject("ADODB.Recordset")
Dim Disclaimer
Disclaimer = "
" & _
"
Dossier à traiter avec confidentialité et la plus grande discrétion.
" & _
"
Les renseignements apparaissant sur cette inscription sont exacts " & _
" au meilleur de la connaissance du courtier inscripteur.
" & _
"
"
dim vVal,vValG,vValF,vValD, vVal2 'generic variable for multiple uses
'Options d'affichage
'comptant normal ou 50%
C = Request.Form("cmbComptant")
Response.Cookies("Comptant") = C
'Devise
DD = Request.Form("cmbDevise")
Response.Cookies("Devise") = DD
if DD > 0 then
strSQL = "SELECT Nom_devise, Mod_Devise, Symbol_Devise, Date_Devise, Source_Devise FROM tblDevise WHERE ID_Devise = " & DD
RS.Open strSQL, CNRS
if not RS.EOF then
MD = RS.Fields("Mod_Devise")
SD = RS.Fields("Symbol_Devise")
NomDevise = RS.Fields("Nom_devise")
DateDevise = RS.Fields("Date_Devise")
SourceDevise = RS.Fields("Source_Devise")
end if
RS.close
end if
Public Function Div0(ByVal v1, ByVal v2)
If Not IsNull(v1) And Not IsNull(v2) Then
If v2 <> 0 Then
Div0 = v1 / v2
Else
Div0 = 0
End If
End If
End Function
Public Function lignes(str)
lignes =0
if not isNull(str) then
for i=1 to (Len(str)-2)
if(Mid(str,i,2)=vbCrLf) then
lignes = lignes +1
end if
if(Mid(str,i,4)=">>>>") then
lignes = lignes +1
end if
next
end if
if lignes=0 then
lignes=-4
end if
End Function
Public Function CalculerMensualite(ECapital, EDuree, ETaux)
'set the variables
Dim vTaux 'As Double
Dim vPaiement 'As Currency
Dim vDiviseur 'As Double
Dim vNumPaiement 'As Integer
Dim vQuotien 'As Double
Dim vQuotien1 'As Double
If ECapital > 0 And EDuree > 0 Then
vTaux = (ETaux) / 2
vQuotien1 = ((1 + vTaux) ^ 2) - 1
vQuotien = ((1 + vQuotien1) ^ (1 / 12)) - 1
vNumPaiement = EDuree * 12
vDiviseur = (1 - ((1 + vQuotien) ^ (-1 * vNumPaiement))) / vQuotien
if vDiviseur <>0 then vPaiement = ECapital / vDiviseur end if
CalculerMensualite = FormatNumber(vPaiement, 2)
Else
CalculerMensualite = 0
End If
End Function
Public Function CalculerRemb(ECapital, EDuree, ETaux, EAnnees)
'set the variables
Dim vTaux 'As Double
Dim vPaiement 'As Currency
Dim vDiviseur 'As Double
Dim vNumPaiement 'As Integer
Dim vQuotien 'As Double
Dim vQuotien1 'As Double
Dim vSolde 'As Currency
Dim I 'As Byte
Dim J 'As Byte
Dim vCapM 'As Currency
Dim vCapTot 'As Currency
If ECapital > 0 And EDuree > 0 Then
'calcul du paiement mensuel
vTaux = (ETaux) / 2
vQuotien1 = ((1 + vTaux) ^ 2) - 1
vQuotien = ((1 + vQuotien1) ^ (1 / 12)) - 1
vNumPaiement = EDuree * 12
vDiviseur = (1 - ((1 + vQuotien) ^ (-1 * vNumPaiement))) / vQuotien
if vDiviseur <>0 then vPaiement = ECapital / vDiviseur end if
'Calcul du capital payé par fréquence par année sur 5 ans
vSolde = ECapital
vCapTot = 0
For I = 1 To EAnnees
For J = 1 To 12
vCapM = (vPaiement - (vSolde * vQuotien))
vCapTot = vCapTot + vCapM
vSolde = vSolde - vCapM
Next
Next
CalculerRemb = (vCapTot / EAnnees)
Else
CalculerRemb = 0
End If
End Function
Public Function CalculerRembNow(ECapital, EDuree, ETaux, EAnnees,ENow)
'set the variables
Dim vTaux 'As Double
Dim vPaiement 'As Currency
Dim vDiviseur 'As Double
Dim vNumPaiement 'As Integer
Dim vQuotien 'As Double
Dim vQuotien1 'As Double
Dim vSolde 'As Currency
Dim I 'As Byte
Dim J 'As Byte
Dim vCapM 'As Currency
Dim vCapTot 'As Currency
Dim vCapTotNow 'As Currency
If ECapital > 0 And EDuree > 0 Then
'calcul du paiement mensuel
vTaux = (ETaux) / 2
vQuotien1 = ((1 + vTaux) ^ 2) - 1
vQuotien = ((1 + vQuotien1) ^ (1 / 12)) - 1
vNumPaiement = EDuree * 12
vDiviseur = (1 - ((1 + vQuotien) ^ (-1 * vNumPaiement))) / vQuotien
if vDiviseur <>0 then vPaiement = ECapital / vDiviseur end if
'Calcul du capital payé par fréquence par année sur 5 ans
vSolde = ECapital
vCapTot = 0
For I = 1 To EAnnees + ENow
For J = 1 To 12
vCapM = (vPaiement - (vSolde * vQuotien))
vCapTot = vCapTot + vCapM
vSolde = vSolde - vCapM
if I > EAnnees then vCapTotNow = vCapTotNow + vCapM
Next
Next
CalculerRembNow = (vCapTotNow / ENow)
Else
CalculerRembNow = 0
End If
End Function
Public Function CalculerRembJ(ECapital, EDuree, ETaux, EJours)
'set the variables
Dim vTaux 'As Double
Dim vPaiement 'As Currency
Dim vDiviseur 'As Double
Dim vNumPaiement 'As Integer
Dim vQuotien 'As Double
Dim vQuotien1 'As Double
Dim vSolde 'As Currency
Dim I 'As Byte
Dim J 'As Byte
Dim vCapM 'As Currencyreduction
Dim vCapTot 'As Currency
If ECapital > 0 And EDuree > 0 Then
vTaux = (ETaux) / 2
vQuotien1 = ((1 + vTaux) ^ 2) - 1
vQuotien = ((1 + vQuotien1) ^ (1 / 365)) - 1
vNumPaiement = EDuree * 365
vDiviseur = (1 - ((1 + vQuotien) ^ (-1 * vNumPaiement))) / vQuotien
if vDiviseur <>0 then vPaiement = ECapital / vDiviseur end if
vSolde = ECapital
vCapTot = 0
For I = 1 To EJours
vCapM = (vPaiement - (vSolde * vQuotien))
vCapTot = vCapTot + vCapM
vSolde = vSolde - vCapM
Next
CalculerRembJ = vSolde
Else
CalculerRembJ = 0
End If
End Function
Public Function CalculerRembM(ECapital, EDuree, ETaux,NoMois)
Dim vTaux, IYear, IMonth, vSolde, vPaiement, vDiviseur, vNumPaiement, vQuotien, vQuotien1, vInteretM, vCapitalM, vInteretTot, vCapitalTot, vInteretAn, vCapitalAn, vSoldeDebutAn, compteur
If ECapital > 0 And EDuree > 0 Then
vSolde = ECapital
vTaux = ETaux / 100
vTaux = vTaux / 2
vQuotien1 = ((1 + vTaux) ^ 2) - 1
vQuotien = ((1 + vQuotien1) ^ (1 / 12)) - 1
vNumPaiement = EDuree * 12
vDiviseur = (1 - ((1 + vQuotien) ^ (-1 * vNumPaiement))) / vQuotien
if vDiviseur <>0 then vPaiement = vSolde / vDiviseur end if
vInteretTot = 0
vCapitalTot = 0
compteur =0
for IYear = 1 to EDuree
for IMonth = 1 to 12
'Année-mois
vInteretM = vSolde * vQuotien
vCapitalM = vPaiement - vInteretM
vInteretAn = vInteretAn + vInteretM
vCapitalAn = vCapitalAn + vCapitalM
vInteretTot = vInteretTot + vInteretM
vCapitalTot = vCapitalTot + vCapitalM
vSolde = vSolde-vCapitalM
compteur = compteur +1
if compteur = NoMois then CalculerRembM = vSolde end if
next
vInteretAn = 0
vCapitalAn = 0
next
Else
CalculerRembM = 0
End If
End Function
Public function ShowProjection()
if RS.Fields("final") <> true then
Response.Write "Version préliminaire "
else
Response.Write "Listing complet"
end if
End function
Public function ShowDateP
if RS.Fields("dateVers") <> "" then
Response.Write"" & RS.Fields ("dateVers")
end if
End function
Public function PN(vVal)
if IsNull(vVal) or vVal =0 or vVal ="" then
PN ="??"
elseif vVal =111111 or vVal = 1195988 or vVal = 1333332 then
PN ="N/A"
else
if P then
dim I
dim vRet
vRet = "----"
for I = 1 to len(vVal)
vRet = vRet & ""
next
PN = vRet
else
PN = vVal
end if
end if
end function
Public function PN2(vVal)
if vVal =0 then
PN2 = ""
else
PN2 = vVal
end if
end function
Public function PN3(vVal)
if vVal =0 or vVal= 111111 then
PN3 = "N/A"
else
PN3 = vVal
end if
end function
Public function lettreOpen(rid)
if rid <> RS.Fields("ID_res") and RS.Fields("Open_Listing") then
if rid < 300 then
lettreOpen = "Z"
elseif rid >1499 then
lettreOpen = "H"
else lettreOpen = "B"
end if
end if
end function
Public function lettreVF(rid)
if rid <> RS.Fields("ID_res") then
if RS.Fields("Temp") then
lettreVF = "VF"
end if
end if
end function
Public function PN5(vVal)
if vVal =0 or vVal= 111111 then
PN5 = "---"
else
PN5 = vVal
end if
end function
Public function PS(vVal)
if P then
PS = ""
else
PS = vVal
end if
end function
Public function PNul(vVal)
if isNull(vVal) then
PNul = "?"
elseif vVal="0" or vVal="" then
PNul = "?"
elseif vVal="111111" then
PNul = "N/A"
else
PNul = vVal
end if
end function
Public function PN4(vVal)
if isNull(vVal) then
PN4 = 111111
else
PN4 = vVal
end if
end function
Public function Onze(vVal)
if vVal= 111111 then
vVal =0
end if
end function
Public function PNF(vVal)
if Len(vVal) >0 then
vVal = "-"& vVal
end if
end function
Public function Prct(vVal)
if vVal="0" then
Prct = "n/a"
elseif Len(vVal) =1 then
Prct = "_"& vVal
else
Prct = vVal
end if
end function
Public function deuxChiffre(vVal)
if Len(vVal) =1 then
deuxChiffre = "0"& vVal
else
deuxChiffre = vVal
end if
end function
Public function Prct0(vVal)
if vVal ="(0%)" then
Prct0 = " "& vVal
else
Prct0 = vVal
end if
end function
Public function PNC(vVal)
if vVal= "111111" then
PNC = "N/A"
else
PNC = vVal
end if
end function
Public function PNzero(vVal)
if vVal= "" then
PNzero = 0
else
PNzero = vVal
end if
end function
Public function Annexe(vVal)
Annexe = "(??)"
if vVal= 0 then Annexe = "(non)" end if
if vVal= 1 then Annexe = "(oui)" end if
if vVal= 2 then Annexe = "(à venir)" end if
if vVal= 3 then Annexe = "(N/A)" end if
end function
Public function NullZero(vVal)
if isNull(vVal) then
NullZero=0
else
NullZero = vVal
end if
end function
Public function DifAnne(vVal)
if vVal< 1 then DifAnne = "Moins de 1 ans" end if
if vVal >= 1 and vVal<5 then DifAnne = "Plus de 1 ans / "& Prct(vVal) end if
if vVal>=5 then DifAnne = "Plus de 5 ans / "& Prct(vVal) end if
end function
Public function ck(vVal)
if vVal= 1 then
ck = "oui"
elseif vVal= 2 then
ck = "non"
else
ck = "???"
end if
end function
Public function SautPage(nrLignes,nrPermis,nrPage)
if nrLignes + nrPermis > 45 then
%>
<% for I=2 to ( 36- nrLignes)%>
align="left" <%elseif I mod 3 = 2 then %> align="center" <%else%> align="right" <%end if %> >
<%if I mod 3 = 1 then %> ventilation des salaires<%end if %>
 
LISTING COMPLET #<%=lettreVF(resId) %><%=resId%><%=lettreOpen(resId) %>
<%if RS.Fields("Titre")=1 then %>RÉSIDENCE POUR PERSONNES ÂGÉES<%END IF %>
<%if RS.Fields("Titre")=2 then %>RESSOURCE INTERMEDIAIRE EN SANTÉ MENTALE<%END IF %>
<%if RS.Fields("Titre")=3 then %>RESSOURCE DE TYPE FAMILIALE<%END IF %>
<%if RS.Fields("Titre")=4 then %>APPARTEMENTS LOCATIFS – STANDARD<%END IF %>
<%if RS.Fields("Categ")=1 then %>Complexe d'appartement sans service<%END IF %>
<%if RS.Fields("Categ")=2 then %>Complexe d'appartement avec service<%END IF %>
<%if RS.Fields("Categ")=3 then %>Ressource intermediaire gerontologie<%END IF %>
<%if RS.Fields("Categ")=4 then %>Ressource intermediaire gerontologie<%END IF %>
<%if RS.Fields("Categ")=11 then %>Chsld public<%END IF %>
<%if RS.Fields("Categ")=5 then %>Chsld privé autofinancé<%END IF %>
<%if RS.Fields("Categ")=6 then %>Chsld conventionné<%END IF %>
<%if RS.Fields("Categ")=7 then %>Clientele privé santé mentale<%END IF %>
<%if RS.Fields("Categ")=8 then %>Clientele privé en lourde perte d'autonomie<%END IF %>
<%if RS.Fields("Categ")=9 then %>Repas et services inclus<%END IF %>
<%if RS.Fields("Categ")=10 then %>Osbl<%END IF %>
<%if RS.Fields("SCateg1") then %>Chambres privées <%END IF %>
<%if RS.Fields("SCateg2") then %>Studios privés <%END IF %>
<%if RS.Fields("SCateg3") then %>Achat service<%END IF %>
<%if RS.Fields("SCateg5") then %>Appartements avec service<%END IF %>
<%ShowProjection()%> / <%ShowDateP()%>
<% if RS.Fields("Open_Listing") = 0 then %>
*Richard Perreault Immobilier Inc. agit uniquement comme courtier pour le vendeur et non pas comme courtier de l’acheteur
<%else %>
*Richard Perreault Immobilier Inc. agit uniquement comme courtier pour l’acheteur et non pas comme courtier du vendeur
<%end if %>
Prix : <%=PN(FormatNumber(RS.Fields("moPrix") * MD, 0, , , true))%> <%=SD%>
Unités : <%=RS.Fields("chUnite")%>
<%end if %>
DESCRIPTION
<%lnp=lnp+1 %>
<% if Cr1 >0 then
strSQL = " SELECT c.ID_Cre ,c.ID_TypeCreancier ,c.ID_TypePret,c.Schl" & _
" FROM tblCreancier AS c,tblTypeCreancier AS t " & _
" WHERE c.ID_TypeCreancier = t.ID_TypeCreancier AND c.ID_Listing = " & vID &" AND c.ID_TypePret=1"
RS2.Open strSQL, CNRS
if RS2.Fields("Schl") then sc=1 end if
RS2.Close
end if %>
<%
dim Balance,Cr1
Balance = 0
strSQL = " SELECT Hypotheque_cre" & _
" FROM tblCreancier" & _
" WHERE ID_Listing = " & vID & " AND ID_TypePret = 2 "
RS2.Open strSQL, CNRS
do while not RS2.EOF
Balance = Balance + RS2.Fields("Hypotheque_cre")
RS2.MoveNext
loop
RS2.Close%>
<%
dim BalanceAss
BalanceAss = 0
strSQL = " SELECT Hypotheque_cre" & _
" FROM tblCreancier" & _
" WHERE ID_Listing = " & vID & " AND ID_TypePret = 5 AND ID_Cre <> "& renouv1 & " AND ID_Cre <> "& renouv2
RS2.Open strSQL, CNRS
do while not RS2.EOF
BalanceAss = BalanceAss + RS2.Fields("Hypotheque_cre")
RS2.MoveNext
loop
RS2.Close %>
<%if RS.Fields("dgDimBatiment")= "0" then %> ?
<%else %>
<%=Str2ProperCase(RS.Fields("dgDimBatiment"))%><%end if %>
<%lnp=lnp+1 %>
<% Dim batiments,etageBat
RS2.Open " SELECT COUNT (Nr_Bat) AS nrB" & _
" FROM tblBatiment" & _
" WHERE ID_Listing = " & vID,CNRS
batiments = RS2.Fields(0)
RS2.Close
if batiments =0 then
if RS.Fields("dgNbrEtages")="" then
etageBat =1
else
etageBat = RS.Fields("dgNbrEtages")
end if
%>
<%if RS.Fields("dgSuperficieSousol")<>0 then %>
<%
strSQL = " SELECT t.Nom_Langue" & _
" FROM tblLangueParlee AS l INNER JOIN tblLangue AS t ON l.ID_Langue = t.ID_Langue" & _
" WHERE l.ID_Listing = " & vID & _
" ORDER BY t.Nom_Langue ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
Response.Write Str2ProperCase(RS2.fields("Nom_Langue"))
RS2.MoveNext
If Not RS2.EOF Then Response.Write ", "
Loop
RS2.Close
%>
<%lnp=lnp+1 %>
<%
if batiments < 2 then
%>
<%lnp=lnp+1 %>
<%end if %>
Clientèle
<%lnp=lnp+1 %>
<%
strSQL = " SELECT t.Nom_TypeClientele" & _
" FROM tblClientele AS c INNER JOIN tblTypeClientele AS t ON c.ID_TypeClientele = t.ID_TypeClientele" & _
" WHERE c.ID_Listing = " & vID & _
" ORDER BY t.Nom_TypeClientele ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
Response.Write Str2ProperCase(RS2.fields("Nom_TypeClientele"))
RS2.MoveNext
If Not RS2.EOF Then
Response.Write " "
lnp=lnp+1
end if
Loop
RS2.Close
%>
<%lnp=lnp+1 %>
<%
if batiments < 2 then
%>
<%lnp=lnp+1 %>
<%end if %>
À proximité
<%lnp=lnp+1 %>
<%
strSQL = " SELECT t.Nom_TypeService" & _
" FROM tblService AS s INNER JOIN tblTypeService AS t ON s.ID_TypeService = t.ID_TypeService" & _
" WHERE s.ID_Listing = " & vID & _
" ORDER BY t.Nom_TypeService;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
Response.Write Str2ProperCase(RS2.fields("Nom_TypeService"))
RS2.MoveNext
If Not RS2.EOF Then
Response.Write " "
lnp=lnp+1
end if
Loop
RS2.Close
%>
<%lnp=lnp+1 %>
<%
if batiments < 2 then
%>
<%lnp=lnp+1 %>
<%end if %>
<%Dim maxLp
maxLp = 44
%>
<%
if batiments > 1 then
%>
<%dim couleur
lnp=lnp+1 %>
Services
<%lnp=lnp+2 %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
Salle commune
:
<%=ck(RS.Fields("dgSalleCommune"))%>
Buanderie
:
<%=ck(RS.Fields("dgBuanderie"))%>
<%lnp=lnp+1 %>
<% couleur = couleur+1 %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt" >
Balcons privés
:
<%=ck(RS.Fields("dgBalconPrive"))%>
Balcons communs
:
<%=ck(RS.Fields("dgBalconCommun"))%>
<%lnp=lnp+1 %>
<% couleur = couleur+1 %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
Piscine intérieure
:
<%=ck(RS.Fields("dgPiscineInt"))%>
Piscine extérieure
:
<%=ck(RS.Fields("dgPiscineExt"))%>
<%lnp=lnp+1 %>
<% couleur = couleur+1 %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
Cour privée
:
<%=ck(RS.Fields("dgCourPrive"))%>
Chapelle
:
<%=ck(RS.Fields("dgChapelle"))%>
<%lnp=lnp+1 %>
<% couleur = couleur+1%>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
Salle d'exercice
:
<%=ck(RS.Fields("SalleExercice"))%>
Spa intérieur
:
<%=ck(RS.Fields("SpaInt"))%>
<%lnp=lnp+1 %>
<% couleur = couleur+1 %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
Salle de billiards
:
<%=ck(RS.Fields("Biliard"))%>
Bain thérapeutique
:
<%=ck(RS.Fields("BainT"))%>
<%lnp=lnp+1 %>
<% couleur = couleur+1 %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
Local-pharmacie
:
<%=ck(RS.Fields("Pharmacie"))%>
Salon de coiffure
:
<%=ck(RS.Fields("Coiffure"))%>
<%lnp=lnp+1 %>
<% couleur = couleur+1 %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
Bureau médecin
:
<%=ck(RS.Fields("Medecin"))%>
Local-infirmerie
:
<%=ck(RS.Fields("Infirmerie"))%>
<%lnp=lnp+1 %>
<% couleur = couleur+1 %>
Facilités
Sécurité
<%lnp=lnp+2 %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
Photographie
:
<%=ck(RS.Fields("dgPhoto"))%>
Boutons panique
:
<%=ck(RS.Fields("dgSysAppel"))%>
<%lnp=lnp+1 %>
<% couleur = couleur+1 %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt" >
Aide au bain
:
<%=ck(RS.Fields("dgAideBain"))%>
Carte magnétique
:
<%=ck(RS.Fields("dgCameras"))%>
<%lnp=lnp+1 %>
<% couleur = couleur+1 %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
Hébergement
:
<%=ck(RS.Fields("dgHebergTemp"))%>
Panneau d'incendie
:
<%=ck(RS.Fields("dgPanneauIncendie"))%>
<%lnp=lnp+1 %>
<% couleur = couleur+1 %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
Comité de résidents
:
<%=ck(RS.Fields("dgComite"))%>
Génératrice
:
<%=ck(RS.Fields("dgGeneratrice"))%>
<%lnp=lnp+1 %>
<% couleur = couleur+1%>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
Meubles et literie
:
<%=ck(RS.Fields("dgMeubles"))%>
Transports spéciaux
:
<%=ck(RS.Fields("dgTransport"))%>
<%lnp=lnp+1 %>
<% couleur = couleur+1 %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
Aspirateur central
:
<%=ck(RS.Fields("dgAspirateur"))%>
Sonnette d’urgence
:
<%=ck(RS.Fields("dgSonnette"))%>
<%lnp=lnp+1 %>
<% couleur = couleur+1 %>
<%end if %>
<% for I=lnp+1 to maxLp %>
<%if I mod 3 = 1 then %> description <%end if %>
<%next %>
<%if RS.Fields("moPrixV") <> 0 then %>
<%lnp=1
else
lnp=0
end if
%>
BÂTIMENT
<%lnp=lnp+1 %>
Spécifications
<%lnp=lnp+1 %>
<% Dim colorB
colorB=0
if batiments > 1 then
%>
bgcolor="#CCCCCC" <% end if%>>
Nombre/nom(batiments)
:
<%=batiments %> =>
<% Dim nrBat
nrBat =1
strSQL = " SELECT Titre " & _
" FROM tblBatiment" & _
" WHERE ID_Listing = " & vID
RS2.Open strSQL, CNRS
Do While Not RS2.EOF %>
<%=RS2.Fields("Titre")%>
<%if nrBat <> batiments then %>/<%end if %>
<% RS2.MoveNext
nrBat = nrBat +1
loop
RS2.Close%>
<%lnp=lnp+3 %>
<%end if
colorB=colorB+1 %>
<% if RS.Fields("DateReno_res") = "111111" then
%>
bgcolor="#CCCCCC" <% end if%>>
Rénovations
:
N/A
<%lnp=lnp+1 %>
<% else %>
bgcolor="#CCCCCC" <% end if%>>
Rénovations
:
<%if isNull(RS.Fields("DateReno_res")) then %> ?
<%else %><%=RS.Fields("DateReno_res")%> <% end if%>
<%lnp=lnp+1 %>
<% end if
colorB=colorB+1%>
<% if RS.Fields("DateAgr_res") = "111111" then %>
bgcolor="#CCCCCC" <% end if%>>
Agrandissement
:
N/A
<%lnp=lnp+1 %>
<% elseif RS.Fields("DateAgr_res") = "" then %>
bgcolor="#CCCCCC" <% end if%>>
Agrandissements
:
NON
<%lnp=lnp+1 %>
<% else %>
bgcolor="#CCCCCC" <% end if%>>
Agrandissement
:
<%=RS.Fields("DateAgr_res")%>
<%lnp=lnp+1 %>
<% end if
colorB=colorB+1%>
<% if batiments > 1 then %>
par BÂTIMENT
<%lnp=lnp+1 %>
<%end if %>
bgcolor="#CCCCCC" <% end if%>>
1 then %>style="border-left-style:solid; border-left-color:#CC0000"<%end if %>>Niveaux
:
<%if batiments > 1 then %>
<% nrBat =1
strSQL = " SELECT Titre,Etages,Sup_ss " & _
" FROM tblBatiment" & _
" WHERE ID_Listing = " & vID
RS2.Open strSQL, CNRS
Do While Not RS2.EOF %>
<%=RS2.Fields("Titre")%>= <%=RS2.Fields("Etages")%><%if RS2.Fields("Sup_ss")>0 then %> + Sous-sol
<%end if %>
<%if nrBat <> batiments then %> / <%end if %>
<% RS2.MoveNext
nrBat = nrBat +1
loop
RS2.Close%> <%lnp=lnp+1 %>
<%else %>
<%=Str2ProperCase(RS.Fields("dgNbrEtages"))%>
<%if RS.Fields("Sousol")=1 or RS.Fields("Sousol")=2 then %> + Sous-sol
<%end if
end if
colorB=colorB+1%>
<%lnp=lnp+1 %>
<% if batiments > 1 then %>
bgcolor="#CCCCCC" <% end if%>>
1 then %>style="border-left-style:solid; border-left-color:#CC0000"<%end if %>>
Superficie sous-sol
:
<%Dim bss,brc,bet
bss=0
brc=0
bet=0
nrBat = 1
strSQL = " SELECT Titre,Sup_ss " & _
" FROM tblBatiment" & _
" WHERE ID_Listing = " & vID
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
if(RS2.Fields("Sup_ss"))<>111111 then bss=RS2.Fields("Sup_ss") end if %>
<%=RS2.Fields("Titre")%>=
<%=PN3(bss)%> pi²
<%if nrBat <> batiments then %> <%lnp=lnp+1 %> <%end if %>
<% RS2.MoveNext
nrBat = nrBat +1
loop
RS2.Close
colorB=colorB+1%>
<%lnp=lnp+1 %>
bgcolor="#CCCCCC" <% end if%>>
1 then %>style="border-left-style:solid; border-left-color:#CC0000"<%end if %>>
Superficie(sous-sol inclus)
:
<%
bss=0
brc=0
bet=0
nrBat = 1
strSQL = " SELECT Titre,Sup_ss,Sup_rc,Sup_et,Etages " & _
" FROM tblBatiment" & _
" WHERE ID_Listing = " & vID
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
if(RS2.Fields("Sup_ss"))<>111111 then bss=RS2.Fields("Sup_ss") end if
if(RS2.Fields("Sup_rc"))<>111111 then brc=RS2.Fields("Sup_rc") end if
if(RS2.Fields("Sup_et"))<>111111 then bet=RS2.Fields("Sup_et")*(RS2.Fields("Etages")-1) end if %>
<%=RS2.Fields("Titre")%>=
<%=PN3(bss+brc +bet) %> pi²
<%if nrBat <> batiments then %> <%lnp=lnp+1 %> <%end if %>
<% RS2.MoveNext
nrBat = nrBat +1
loop
RS2.Close
colorB=colorB+1%>
<%lnp=lnp+1 %>
bgcolor="#CCCCCC" <% end if%>>
1 then %>style="border-left-style:solid; border-left-color:#CC0000"<%end if %>> Unités
:
<% nrBat =1
strSQL = " SELECT Titre,NrUnit " & _
" FROM tblBatiment" & _
" WHERE ID_Listing = " & vID
RS2.Open strSQL, CNRS
Do While Not RS2.EOF %>
<%=RS2.Fields("Titre")%>= <%=RS2.Fields("NrUnit")%> unités
<%if nrBat <> batiments then %> <%lnp=lnp+1 %><%end if %>
<% RS2.MoveNext
nrBat = nrBat +1
loop
RS2.Close
colorB=colorB+1%>
<%lnp=lnp+1 %>
bgcolor="#CCCCCC" <% end if%>>
1 then %>style="border-left-style:solid; border-left-color:#CC0000"<%end if %>>
Toiture
:
<% nrBat =1
strSQL = " SELECT Titre,Toiture " & _
" FROM tblBatiment" & _
" WHERE ID_Listing = " & vID
RS2.Open strSQL, CNRS
Do While Not RS2.EOF %>
<%=RS2.Fields("Titre")%>=
<%if RS2.Fields("Toiture")=0 then%>pignon
<%else %>plate<%end if %>
<%if nrBat <> batiments then %> <%lnp=lnp+1 %><%end if %>
<% RS2.MoveNext
nrBat = nrBat +1
loop
RS2.Close
colorB=colorB+1%>
<%lnp=lnp+1 %>
<%end if %>
bgcolor="#CCCCCC" <% end if%>>
1 then %>style="border-left-style:solid; border-left-color:#CC0000"<%end if %>>Recouvrement extérieur
:
<%if batiments > 1 then %>
<% nrBat =1
strSQL = " SELECT Titre,Recouv " & _
" FROM tblBatiment" & _
" WHERE ID_Listing = " & vID
RS2.Open strSQL, CNRS
Do While Not RS2.EOF %>
<%=RS2.Fields("Titre")%>=
<%if RS2.Fields("Recouv")=0 then%>?<%end if %>
<%if RS2.Fields("Recouv")=1 then %>brique<%end if %>
<%if RS2.Fields("Recouv")=2 then %>brique & aluminium<%end if %>
<%if RS2.Fields("Recouv")=3 then %>vinyle & agregat<%end if %>
<%if RS2.Fields("Recouv")=4 then %>aluminium,agregat et acier<%end if %>
<%if RS2.Fields("Recouv")=5 then %>déclin de bois<%end if %>
<%if RS2.Fields("Recouv")=6 then%>pierre & vinyle<%end if %>
<%if RS2.Fields("Recouv")=7 then %>déclin de vinyle<%end if %>
<%if RS2.Fields("Recouv")=8 then %>déclin d'aluminium<%end if %>
<%if RS2.Fields("Recouv")=9 then %>brique & vinyle<%end if %>
<%if RS2.Fields("Recouv")=10 then %>brique & stuc<%end if %>
<%if RS2.Fields("Recouv")=11 then %>brique & canexel<%end if %>
<%if RS2.Fields("Recouv")=12 then %>stucco & agregat<%end if %>
<%if nrBat <> batiments then %> <%lnp=lnp+1 %><%end if %>
<% RS2.MoveNext
nrBat = nrBat +1
loop
RS2.Close%>
<%else %>
<%if isNull(RS.Fields("Nom_TypeRecouvrement")) then %> ?
<%else %><%=Str2ProperCase(RS.Fields("Nom_TypeRecouvrement"))%><%end if %>
<%end if
colorB=colorB+1%>
<%lnp=lnp+1 %>
bgcolor="#CCCCCC" <% end if%>>
1 then %>style="border-left-style:solid; border-left-color:#CC0000"<%end if %>>
Année construction
:
1 then %>class="texte-8pt"<%else %>class="texte-8pt" <%end if %>>
<%if batiments > 1 then %>
<% nrBat =1
strSQL = " SELECT Titre,Constr " & _
" FROM tblBatiment" & _
" WHERE ID_Listing = " & vID
RS2.Open strSQL, CNRS
Do While Not RS2.EOF %>
<%=RS2.Fields("Titre")%>= <%if RS2.Fields("Constr") =0 then %>?
<%else %><%=Str2ProperCase(RS2.Fields("Constr"))%><%end if %>
<%if nrBat <> batiments then %> / <%end if %>
<% RS2.MoveNext
nrBat = nrBat +1
loop
RS2.Close%>
<%else %>
<% if RS.Fields("DateCons_res")<> "" then %>
<% =RS.Fields("DateCons_res")%>
<%else %>Inconnue<%end if %>
<%end if
colorB=colorB+1 %>
<%lnp=lnp+1 %>
bgcolor="#CCCCCC" <% end if%>>
1 then %>style="border-left-style:solid; border-left-color:#CC0000"<%end if %>>Structure
:
<%if batiments > 1 then %>
<% nrBat = 1
strSQL = " SELECT Titre,Struct " & _
" FROM tblBatiment" & _
" WHERE ID_Listing = " & vID
RS2.Open strSQL, CNRS
Do While Not RS2.EOF %>
<%=RS2.Fields("Titre")%>=
<%if RS2.Fields("Struct")=0 then %>?<%end if %>
<%if RS2.Fields("Struct")=1 then %>bois<%end if %>
<%if RS2.Fields("Struct")=2 then %>béton<%end if %>
<%if RS2.Fields("Struct")=3 then %>bois / béton<%end if %>
<%if RS2.Fields("Struct")=4 then %>acier / béton<%end if %>
<%if RS2.Fields("Struct")=5 then %>bois acier béton<%end if %>
<%if nrBat <> batiments then %> <%lnp=lnp+1 %><%end if %>
<% RS2.MoveNext
nrBat = nrBat +1
loop
RS2.Close%>
<%else %>
<%if isNull(RS.Fields("Nom_TypeConstruction")) then %> ?
<%else %><%=Str2ProperCase(RS.Fields("Nom_TypeConstruction"))%><%end if %>
<%end if
colorB=colorB+1 %>
<%lnp=lnp+1 %>
bgcolor="#CCCCCC" <% end if%>>
1 then %>style="border-left-style:solid; border-left-color:#CC0000"<%end if %>>Ascenseur
:
<%if batiments > 1 then %>
<% nrBat =1
strSQL = " SELECT Titre,Ascenseurs " & _
" FROM tblBatiment" & _
" WHERE ID_Listing = " & vID
RS2.Open strSQL, CNRS
Do While Not RS2.EOF %>
<%=RS2.Fields("Titre")%>= <%if RS2.Fields("Ascenseurs") =0 then %>??
<%elseif RS2.Fields("Ascenseurs") =111111 then %>N/A
<%else %><%=Str2ProperCase(RS2.Fields("Ascenseurs"))%><%end if %>
<%if nrBat <> batiments then %> / <%end if %>
<% RS2.MoveNext
nrBat = nrBat +1
loop
RS2.Close%>
<%else %>
<%if RS.Fields("dgAscenseur") =0 then %> ??
<%elseif RS.Fields("dgAscenseur") =111111 then %> N/A
<%else %><%=Str2ProperCase(RS.Fields("dgAscenseur"))%><%end if %>
<%end if
colorB=colorB+1 %>
<%lnp=lnp+1 %>
bgcolor="#CCCCCC" <% end if%>>
1 then %>style="border-left-style:solid; border-left-color:#CC0000"<%end if %> >
Classe
:
<%if batiments > 1 then %>
<% nrBat = 1
strSQL = " SELECT Titre,Classe " & _
" FROM tblBatiment" & _
" WHERE ID_Listing = " & vID
RS2.Open strSQL, CNRS
Do While Not RS2.EOF %>
<%=RS2.Fields("Titre")%>=
<%if RS2.Fields("Classe")=0 then %>?<%end if %>
<%if RS2.Fields("Classe")=1 then %>C<%end if %>
<%if RS2.Fields("Classe")=2 then %>autres<%end if %>
<%if RS2.Fields("Classe")=3 then %>B2<%end if %>
<%if RS2.Fields("Classe")=4 then %>B2 + C<%end if %>
<%if RS2.Fields("Classe")=5 then %>R<%end if %>
<%if nrBat <> batiments then %> / <%end if %>
<% RS2.MoveNext
nrBat = nrBat +1
loop
RS2.Close%>
<%else %>
<%=Str2ProperCase(RS.Fields("Nom_Classe"))%>
<%end if
colorB=colorB+1%>
<%lnp=lnp+1 %>
<%if batiments > 1 then %>
<%end if %>
bgcolor="#CCCCCC" <% end if%>>
Eau chaude
:
<%if isNull(RS.Fields("Nom_TypeEauChaude")) then %> ?
<%else %><%=Str2ProperCase(RS.Fields("Nom_TypeEauChaude"))%>
<%end if
colorB=colorB+1 %>
<%lnp=lnp+1 %>
bgcolor="#CCCCCC" <% end if%>>
Équipement cuisine
:
<%if isNull(RS.Fields("Nom_EquipCuisine")) then %> ?
<%else %><%=Str2ProperCase(RS.Fields("Nom_EquipCuisine"))%>
<%end if
colorB=colorB+1 %>
<%lnp=lnp+1 %>
<% if not isNull(RS.Fields("Chaise")) and RS.Fields("Chaise") <> "Non" then %>
bgcolor="#CCCCCC" <% end if%>>
Chaise élévatrice
:
<%=Str2ProperCase(RS.Fields("Chaise"))%>
<%lnp=lnp+1 %>
<% colorB=colorB+1
end if %>
bgcolor="#CCCCCC" <% end if%>>
Chauffage
:
<%if isNull(RS.Fields("Nom_TypeChauffage")) then %> ?
<%else %><%=Str2ProperCase(RS.Fields("Nom_TypeChauffage"))%>
<%end if
colorB=colorB+1 %>
<%lnp=lnp+1 %>
bgcolor="#CCCCCC" <% end if%>>
Cable payé par
:
<% if RS.Fields("Nom_TypeCable")<> "' '" then %> <%=Str2ProperCase(RS.Fields("Nom_TypeCable"))%>
<%else %>?
<% end if
colorB=colorB+1%>
<%lnp=lnp+1 %>
bgcolor="#CCCCCC" <% end if%>>
Fournisseur cable
:
<% if RS.Fields("Nom_TypeFCable")<> "' '" then %> <%=Str2ProperCase(RS.Fields("Nom_TypeFCable"))%>
<%else %>?
<% end if
colorB=colorB+1%>
<%lnp=lnp+1 %>
bgcolor="#CCCCCC" <% end if%>>
Gicleurs
:
<%if RS.Fields("Gicleurs")=0 then %>??<%end if %>
<%if RS.Fields("Gicleurs")=1 then %>Oui 100%<%end if %>
<%if RS.Fields("Gicleurs")=2 then %>Oui partiellement<%end if %>
<%if RS.Fields("Gicleurs")=3 then %>Non<%end if %>
<% colorB=colorB+1 %>
<%lnp=lnp+1 %>
bgcolor="#CCCCCC" <% end if%>>
Espaces climatisés
:
<%if RS.Fields("Climat")=1 then %>Espaces communs seulement<%end if %>
<%if RS.Fields("Climat")=2 then %>Complètement<%end if %>
<%if RS.Fields("Climat")=3 then %>Bureaux seulement<%end if %>
<%if RS.Fields("Climat")=0 then %>??<%end if %>
<%if RS.Fields("Climat")=4 then %>Bureau & Salle a manger<%end if %>
<%if RS.Fields("Climat")=5 then %>Rien<%end if %>
<% colorB=colorB+1 %>
<%lnp=lnp+1 %>
<%if RS.Fields("EchAir")=0 then %>
bgcolor="#CCCCCC" <% end if%>>
Échangeur d'air
:
<%if RS.Fields("EchAir")=0 then %>Non
<%elseif RS.Fields("EchAir")=1 then %>Oui
<%else%>?<%end if %> <% colorB=colorB+1 %>
<%lnp=lnp+1 %>
<%end if %>
bgcolor="#CCCCCC" <% end if%>>
Caméras de surveillance
:
<%if RS.Fields("CamSurv")=-2 then %>??
<%elseif RS.Fields("CamSurv")=-1 then %>Non
<%elseif RS.Fields("CamSurv")=0 then %>Oui
<%else%>Oui (<%=RS.Fields("CamSurv")%>)
<%end if %>
<% colorB=colorB+1 %>
<%lnp=lnp+1 %>
<% if RS.Fields("Nom_TypeLogProp")<> "NON" then %>
bgcolor="#CCCCCC" <% end if%>>
Logement proprietaire
:
<% if RS.Fields("Nom_TypeLogProp")<> "' '" then %> <%=Str2ProperCase(RS.Fields("Nom_TypeLogProp"))%><%else %>??<% end if%>
<%end if
end if%>
<% dim RDB_AR2,RDC_AR2,Vacantloyers,PercVL, Occloyers,OccloyersSoins,pic,RDDred,RDG_a,RDI_a,color,depenseC,dep1,dep2,dep3,dep4 ,dep5,dep6,dep7,dep8,dep9,depG,RDCTact,RDEact,RDGact,RDIact,nonRes
nonRes=0
strSQL = " SELECT Count(*) AS nrSal" & _
" FROM tblSalaires" & _
" WHERE (Titre ='26') and ID_Listing = " & vID
RS2.Open strSQL, CNRS
nrSal = RS2.Fields(0)
RS2.Close
if nrSal > 0 then %>
<%
RS2.Open " SELECT SUM (Tarif)" & _
" FROM tblLoyers" & _
" WHERE Tarif<>111111 and ID_Listing = " & vID,CNRS
%>
<% Occloyers = 12 * RS2.Fields(0)
RS2.Close%>
<%
RS2.Open " SELECT SUM (Soin)" & _
" FROM tblLoyers" & _
" WHERE Soin<>111111 and ID_Listing = " & vID,CNRS
%>
<% OccloyersSoins = 12 * RS2.Fields(0)
RS2.Close%>
<% if isnull(Occloyers) then Occloyers = 0 end if
if isnull(OccloyersSoins) then OccloyersSoins = 0 end if
%>
<% if Occloyers <> 0 then
RDB = Occloyers + OccloyersSoins
else
RDB =RS.Fields("moRevenuBrut")
end if
if isnull(RDB) then RDB = 0 end if
%>
A- Revenu brut résidentiel:
<%=PN(FormatNumber(RDB * MD, 0, , , true))%> $
<% RDA = RS.Fields("moRevenuActuel")
%>
Revenu à la signature du mandat
Mensuel: <%=PN(FormatNumber(RDA * MD, 0, , , true))%> $ /
Annuel: <%=PN(FormatNumber((RDA * 12) * MD, 0, , , true))%> $
<% Dim RDC_ARa, RDC_AR2a
RDB_AR2 = RS.Fields("AutresRev2")
RDB_AR = RS.Fields("AutresRev")
RDC_ARa = RDB_AR - RS.Fields("VacAutresRevA")
RDC_AR2a = RDB_AR2 - RS.Fields("VacAutresRev2A") %>
<% if RDB_AR2 = 111111 then
RDB_AR2 = 0
RDC_AR2a =0
end if %>
<% if RDB_AR =111111 then
RDB_AR = 0
RDC_ARa =0
end if %>
<%
if RDB_AR2 <> 0 and RDB_AR2 <> 111111 then
nonRes=1 %>
<%
RS2.Open " SELECT SUM (Tarif)" & _
" FROM tblLoyers" & _
" WHERE Tarif<>111111 and ID_Listing = " & vID,CNRS
%>
<% Occloyers = 12 * RS2.Fields(0)
RS2.Close%>
<%
RS2.Open " SELECT SUM (Soin)" & _
" FROM tblLoyers" & _
" WHERE Soin<>111111 and ID_Listing = " & vID,CNRS
%>
<% OccloyersSoins = 12 * RS2.Fields(0)
RS2.Close%>
<% if isnull(Occloyers) then Occloyers = 0 end if
if isnull(OccloyersSoins) then OccloyersSoins = 0 end if
%>
<% if Occloyers <> 0 then
RDB = Occloyers + OccloyersSoins
else
RDB =RS.Fields("moRevenuBrut")
end if
if isnull(RDB) then RDB = 0 end if
%>
A- Revenu brut résidentiel:
<%=PN(FormatNumber(RDB * MD, 0, , , true))%> $
<% RDA = RS.Fields("moRevenuActuel")
%>
Revenu à la signature du mandat
Mensuel: <%=PN(FormatNumber(RDA * MD, 0, , , true))%> $ /
Annuel: <%=PN(FormatNumber((RDA * 12) * MD, 0, , , true))%> $
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 1 AND 2) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep1 = Round(Div0(RVD,RDBT) * 100,0) %>
Taxes:
<%=PN3(dep1)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<%
if RS.Fields("chUnite")>=25 or (RS.Fields("Categ")=11 or RS.Fields("Categ")=5 or RS.Fields("Categ")=6) then
RVD =salProprio
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 3 AND 7) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RVD + RS2.Fields(0) end if
dep2 = Round(Div0(RVD,RDBT) * 100,0) %>
Salaires:
<%=PN3(dep2)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close
else
dep2=0
%>
Salaires (exclus-voir pg.9):
0%
0 $
<% end if
dim depSt
RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 9 AND 10) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
depSt = Round(Div0(RVD,RDBT) * 100,0)%>
Sous-traitance:
<%=PN3(depSt)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<%
if RS.Fields("chUnite")>=25 and (RS.Fields("Categ")=11 or RS.Fields("Categ")=5 or RS.Fields("Categ")=6) then
RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE t.Rang_Depense = 8 AND d.ID_Listing = " & vID,CNRS
%>
<%
if not isnull(RS2.Fields(0)) then
RVD = RS2.Fields(0)
end if
depG = Round(Div0(RVD,RDBT) * 100,0)
if RVD = 111111 then
depG = 111111
end if%>
Gestion:
<%=PN3(depG)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close
else
dep2=0
end if
RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 11 AND 16) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep3 = Round(Div0(RVD,RDBT) * 100,0)%>
Énergie & télécommunications:
<%=PN3(dep3)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 17 AND 22) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep4 = Round(Div0(RVD,RDBT) * 100,0) %>
Entretien & achat fournitures:
<%=PN3(dep4)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 23 AND 32) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep5 = Round(Div0(RVD,RDBT) * 100,0)%>
Permis & frais financiers:
<%=PN3(dep5)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 33 AND 36)AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep6 = Round(Div0(RVD,RDBT) * 100,0)%>
Location équipement:
<%=PN3(dep6)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE t.Rang_Depense = 37 AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep7 = Round(Div0(RVD,RDBT) * 100,0) %>
Alimentation:
<%=PN3(dep7)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 38 AND 41) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep8 = Round(Div0(RVD,RDBT) * 100,0)%>
Locataire marketing:
<%=PN3(dep8)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE t.Rang_Depense = 42 AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep9 = Round(Div0(RVD,RDBT) * 100,0) %>
Divers:
<%=PN3(dep9)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
CATÉGORIE DE DÉPENSE / DÉPENSES TOTALES
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 1 AND 2) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep1 = Round(Div0(RVD,RDD) * 100,0) %>
Taxes:
<%=PN3(dep1)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<%
if RS.Fields("chUnite")>=25 or (RS.Fields("Categ")=11 or RS.Fields("Categ")=5 or RS.Fields("Categ")=6) then
RVD =salProprio
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 3 AND 7) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RVD + RS2.Fields(0) end if
dep2 = Round(Div0(RVD,RDD) * 100,0) %>
Salaires:
<%=PN3(dep2)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close
else
dep2=0
%>
Salaires (exclus-voir pg.9):
0%
0 $
<% end if
RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 9 AND 10) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
depSt = Round(Div0(RVD,RDD) * 100,0)%>
Sous-traitance:
<%=PN3(depSt)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<%
if RS.Fields("chUnite")>=25 and (RS.Fields("Categ")=11 or RS.Fields("Categ")=5 or RS.Fields("Categ")=6) then
RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE t.Rang_Depense = 8 AND d.ID_Listing = " & vID,CNRS
%>
<%
if not isnull(RS2.Fields(0)) then
RVD = RS2.Fields(0)
end if
depG = Round(Div0(RVD,RDD) * 100,0)
if RVD = 111111 then
depG = 111111
end if%>
Gestion:
<%=PN3(depG)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close
else
dep2=0
end if
RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 11 AND 16) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep3 = Round(Div0(RVD,RDD) * 100,0)%>
Énergie & télécommunications:
<%=PN3(dep3)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 17 AND 22) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep4 = Round(Div0(RVD,RDD) * 100,0) %>
Entretien & achat fournitures:
<%=PN3(dep4)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 23 AND 32) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep5 = Round(Div0(RVD,RDD) * 100,0)%>
Permis & frais financiers:
<%=PN3(dep5)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 33 AND 36)AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep6 = Round(Div0(RVD,RDD) * 100,0)%>
Location équipement:
<%=PN3(dep6)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE t.Rang_Depense = 37 AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep7 = Round(Div0(RVD,RDD) * 100,0) %>
Alimentation:
<%=PN3(dep7)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 38 AND 41) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep8 = Round(Div0(RVD,RDD) * 100,0)%>
Locataire marketing:
<%=PN3(dep8)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE t.Rang_Depense = 42 AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep9 = Round(Div0(RVD,RDD) * 100,0) %>
<%
RS2.Open " SELECT SUM (Tarif)" & _
" FROM tblLoyers" & _
" WHERE Tarif<>111111 and ID_Listing = " & vID,CNRS
%>
<% Occloyers = 12 * RS2.Fields(0)
RS2.Close%>
<%
RS2.Open " SELECT SUM (Soin)" & _
" FROM tblLoyers" & _
" WHERE Soin<>111111 and ID_Listing = " & vID,CNRS
%>
<% OccloyersSoins = 12 * RS2.Fields(0)
RS2.Close%>
<% if isnull(Occloyers) then Occloyers = 0 end if
if isnull(OccloyersSoins) then OccloyersSoins = 0 end if
%>
<% if Occloyers <> 0 then
RDB = Occloyers + OccloyersSoins
else
RDB =RS.Fields("moRevenuBrut")
end if
if isnull(RDB) then RDB = 0 end if
%>
A- Revenu brut résidentiel:
<%=PN(FormatNumber(RDB * MD, 0, , , true))%> $
<% RDA = RS.Fields("moRevenuActuel")
%>
Revenu à la signature du mandat
Mensuel: <%=PN(FormatNumber(RDA * MD, 0, , , true))%> $ /
Annuel: <%=PN(FormatNumber((RDA * 12) * MD, 0, , , true))%> $
<%
RS2.Open " SELECT SUM (Tarif)" & _
" FROM tblLoyers" & _
" WHERE Tarif<>111111 and ID_Listing = " & vID,CNRS
%>
<% Occloyers = 12 * RS2.Fields(0)
RS2.Close%>
<%
RS2.Open " SELECT SUM (Soin)" & _
" FROM tblLoyers" & _
" WHERE Soin<>111111 and ID_Listing = " & vID,CNRS
%>
<% OccloyersSoins = 12 * RS2.Fields(0)
RS2.Close%>
<% if isnull(Occloyers) then Occloyers = 0 end if
if isnull(OccloyersSoins) then OccloyersSoins = 0 end if
%>
<% if Occloyers <> 0 then
RDB = Occloyers + OccloyersSoins
else
RDB =RS.Fields("moRevenuBrut")
end if
if isnull(RDB) then RDB = 0 end if
%>
A- Revenu brut résidentiel:
<%=PN(FormatNumber(RDB * MD, 0, , , true))%> $
<% RDA = RS.Fields("moRevenuActuel")
%>
Revenu à la signature du mandat
Mensuel: <%=PN(FormatNumber(RDA * MD, 0, , , true))%> $ /
Annuel: <%=PN(FormatNumber((RDA * 12) * MD, 0, , , true))%> $
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 1 AND 2) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep1 = Round(Div0(RVD,RDBT) * 100,0) %>
Taxes:
<%=PN3(dep1)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<%
if RS.Fields("chUnite")>=25 or (RS.Fields("Categ")=11 or RS.Fields("Categ")=5 or RS.Fields("Categ")=6) then
RVD =salProprio
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 3 AND 7) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RVD + RS2.Fields(0) end if
dep2 = Round(Div0(RVD,RDBT) * 100,0) %>
Salaires:
<%=PN3(dep2)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close
else
dep2=0
%>
Salaires (exclus-voir pg.9):
0%
0 $
<% end if
RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 9 AND 10) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
depSt = Round(Div0(RVD,RDBT) * 100,0)%>
Sous-traitance:
<%=PN3(depSt)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<%
if RS.Fields("chUnite")>=25 and (RS.Fields("Categ")=11 or RS.Fields("Categ")=5 or RS.Fields("Categ")=6) then
RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE t.Rang_Depense = 8 AND d.ID_Listing = " & vID,CNRS
%>
<%
if not isnull(RS2.Fields(0)) then
RVD = RS2.Fields(0)
end if
depG = Round(Div0(RVD,RDBT) * 100,0)
if RVD = 111111 then
depG = 111111
end if%>
Gestion:
<%=PN3(depG)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close
else
dep2=0
end if
RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 11 AND 16) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep3 = Round(Div0(RVD,RDBT) * 100,0)%>
Énergie & télécommunications:
<%=PN3(dep3)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 17 AND 22) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep4 = Round(Div0(RVD,RDBT) * 100,0) %>
Entretien & achat fournitures:
<%=PN3(dep4)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 23 AND 31) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep5 = Round(Div0(RVD,RDBT) * 100,0)%>
Permis & frais financiers:
<%=PN3(dep5)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 32 AND 36)AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep6 = Round(Div0(RVD,RDBT) * 100,0)%>
Location équipement:
<%=PN3(dep6)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE t.Rang_Depense = 37 AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep7 = Round(Div0(RVD,RDBT) * 100,0) %>
Alimentation:
<%=PN3(dep7)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 38 AND 41) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep8 = Round(Div0(RVD,RDBT) * 100,0)%>
Locataire marketing:
<%=PN3(dep8)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE t.Rang_Depense = 42 AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep9 = Round(Div0(RVD,RDBT) * 100,0) %>
Divers:
<%=PN3(dep9)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
CATÉGORIE DE DÉPENSE / DÉPENSES TOTALES
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 1 AND 2) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep1 = Round(Div0(RVD,RDD) * 100,0) %>
Taxes:
<%=PN3(dep1)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<%
if RS.Fields("chUnite")>=25 or (RS.Fields("Categ")=11 or RS.Fields("Categ")=5 or RS.Fields("Categ")=6) then
RVD =salProprio
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 3 AND 7) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RVD + RS2.Fields(0) end if
dep2 = Round(Div0(RVD,RDD) * 100,0) %>
Salaires:
<%=PN3(dep2)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close
else
dep2=0
%>
Salaires (exclus-voir pg.9):
0%
0 $
<% end if
RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 9 AND 10) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
depSt = Round(Div0(RVD,RDD) * 100,0)%>
Sous-traitance:
<%=PN3(depSt)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<%
if RS.Fields("chUnite")>=25 and (RS.Fields("Categ")=11 or RS.Fields("Categ")=5 or RS.Fields("Categ")=6) then
RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE t.Rang_Depense = 8 AND d.ID_Listing = " & vID,CNRS
%>
<%
if not isnull(RS2.Fields(0)) then
RVD = RS2.Fields(0)
end if
depG = Round(Div0(RVD,RDD) * 100,0)
if RVD = 111111 then
depG = 111111
end if%>
Gestion:
<%=PN3(depG)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close
else
dep2=0
end if
RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 11 AND 16) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep3 = Round(Div0(RVD,RDD) * 100,0)%>
Énergie & télécommunications:
<%=PN3(dep3)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 17 AND 22) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep4 = Round(Div0(RVD,RDD) * 100,0) %>
Entretien & achat fournitures:
<%=PN3(dep4)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 23 AND 31) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep5 = Round(Div0(RVD,RDD) * 100,0)%>
Permis & frais financiers:
<%=PN3(dep5)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 32 AND 36)AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep6 = Round(Div0(RVD,RDD) * 100,0)%>
Location équipement:
<%=PN3(dep6)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE t.Rang_Depense = 37 AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep7 = Round(Div0(RVD,RDD) * 100,0) %>
Alimentation:
<%=PN3(dep7)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 38 AND 41) AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep8 = Round(Div0(RVD,RDD) * 100,0)%>
Locataire marketing:
<%=PN3(dep8)%>%
<%=PN3(FormatNumber(RVD * MD, 0, , , true))%> $
<% RS2.Close %>
<% RVD =0
RS2.Open " SELECT SUM (d.Valeur_Depense) " & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE t.Rang_Depense = 42 AND d.Valeur_Depense<>111111 AND d.ID_Listing = " & vID,CNRS
%>
<% if not isnull(RS2.Fields(0)) then RVD = RS2.Fields(0) end if
dep9 = Round(Div0(RVD,RDD) * 100,0) %>
<%
color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense, t.Pourcentage_Depense" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 1 AND 2) AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
depenseC = RS2.Fields("Valeur_Depense")
if depenseC= 111111 then depenseC=0 end if
pic = pic + Div0(depenseC*100, RS.Fields("dgSuperficieLogement")* VPC)
%>
bgcolor="#CCCCCC" <% end if%>class="v1"><%=RS2.Fields("Nom_TypeDepense")%>
<% color = color +1
RS2.MoveNext
loop
RS2.Close
%>
[<%=PN3(FormatNumber(pic* MD, 0, , , true))%>$]
SALAIRES<% if RS.Fields("chUnite")<25 and RS.Fields("Categ")<>11 and RS.Fields("Categ")<>5 and RS.Fields("Categ")<>6 then%> (exclus-voir pg.9)<%end if %>
<%
pic=0
color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense, t.Pourcentage_Depense" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 3 AND 10) AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
depenseC = RS2.Fields("Valeur_Depense")
if (depenseC= 111111 or depenseC = 111 or ( RS.Fields("chUnite")<25 and RS.Fields("Categ")<>11 and RS.Fields("Categ")<>5 and RS.Fields("Categ")<>6)) then depenseC=0 end if
pic = pic + Div0(depenseC*100, RS.Fields("dgSuperficieLogement")* VPC)
%>
bgcolor="#CCCCCC" <% end if%> class="v1"><%=RS2.Fields("Nom_TypeDepense")%>
<% if RS.Fields("chUnite")<25 and RS.Fields("Categ")<>11 and RS.Fields("Categ")<>5 and RS.Fields("Categ")<>6 then%>
<%
color = color +1
RS2.MoveNext
loop
RS2.Close
%>
[<%=PN3(FormatNumber(pic* MD, 0, , , true))%>$]
ÉNERGIE & TÉLÉCOMUNICATIONS
<% pic=0
color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense, t.Pourcentage_Depense" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 11 AND 16 ) AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
depenseC = RS2.Fields("Valeur_Depense")
if depenseC= 111111 then depenseC=0 end if
pic = pic + Div0(depenseC*100, RS.Fields("dgSuperficieLogement")* VPC) %>
bgcolor="#CCCCCC" <% end if%> class="v1"><%=RS2.Fields("Nom_TypeDepense")%>
<%
color = color +1
RS2.MoveNext
loop
RS2.Close
%>
[<%=PN3(FormatNumber(pic* MD, 0, , , true))%>$]
ENTRETIEN ET ACHAT PRODUITS
<% pic=0
color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense, t.Pourcentage_Depense" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 17 AND 22) AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
depenseC = RS2.Fields("Valeur_Depense")
if depenseC= 111111 then depenseC=0 end if
pic = pic + Div0(depenseC*100, RS.Fields("dgSuperficieLogement")* VPC) %>
bgcolor="#CCCCCC" <% end if%> class="v1"><%=RS2.Fields("Nom_TypeDepense")%>
<%
color = color +1
RS2.MoveNext
loop
RS2.Close
%>
[<%=PN3(FormatNumber(pic* MD, 0, , , true))%>$]
PERMIS & FRAIS FINANCIERS
<% pic=0
color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense, t.Pourcentage_Depense" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 23 AND 32) AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
depenseC = RS2.Fields("Valeur_Depense")
if depenseC= 111111 then depenseC=0 end if
pic = pic + Div0(depenseC*100, RS.Fields("dgSuperficieLogement")* VPC) %>
bgcolor="#CCCCCC" <% end if%> class="v1"><%=RS2.Fields("Nom_TypeDepense")%>
<%
color = color +1
RS2.MoveNext
loop
RS2.Close
%>
[<%=PN3(FormatNumber(pic* MD, 0, , , true))%>$]
LOCATION D'ÉQUIPEMENTS
<% pic=0
color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense, t.Pourcentage_Depense" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 33 AND 36) AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
depenseC = RS2.Fields("Valeur_Depense")
if depenseC= 111111 then depenseC=0 end if
pic = pic + Div0(depenseC*100, RS.Fields("dgSuperficieLogement")* VPC) %>
bgcolor="#CCCCCC" <% end if%> class="v1"><%=RS2.Fields("Nom_TypeDepense")%>
<%
color = color +1
RS2.MoveNext
loop
RS2.Close
%>
[<%=PN3(FormatNumber(pic* MD, 0, , , true))%>$]
<%
color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense, t.Pourcentage_Depense" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE t.Rang_Depense =37 AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
depenseC = RS2.Fields("Valeur_Depense")
if depenseC= 111111 then depenseC=0 end if
%>
<%
color = color +1
RS2.MoveNext
loop
RS2.Close
%>
LOCATAIRE MARKETING
<% pic=0
color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense, t.Pourcentage_Depense" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 38 AND 41) AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
depenseC = RS2.Fields("Valeur_Depense")
if depenseC= 111111 then depenseC=0 end if
pic = pic + Div0(depenseC*100, RS.Fields("dgSuperficieLogement")* VPC) %>
bgcolor="#CCCCCC" <% end if%> class="v1"><%=RS2.Fields("Nom_TypeDepense")%>
<%
color = color +1
RS2.MoveNext
loop
RS2.Close
%>
[<%=PN3(FormatNumber(pic* MD, 0, , , true))%>$]
<%
color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense, t.Pourcentage_Depense" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE t.Rang_Depense =42 AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
depenseC = RS2.Fields("Valeur_Depense")
if depenseC= 111111 then depenseC=0 end if
%>
<%
RS2.Open " SELECT SUM (d.Valeur_Depense) as vRet"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 1 AND 2) AND d.Valeur_Depense <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<%
RS2.Open " SELECT SUM (d.Valeur_Depense2) as vRet2"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 1 AND 2) AND d.Valeur_Depense2 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<%
RS2.Open " SELECT SUM (d.Valeur_Depense3) as vRet3"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 1 AND 2) AND d.Valeur_Depense3 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<%
RS2.Open " SELECT SUM (d.Valeur_Depense4) as vRet4"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 1 AND 2) AND d.Valeur_Depense4 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<%
RS2.Open " SELECT SUM (d.Valeur_Depense5) as vRet5"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 1 AND 2) AND d.Valeur_Depense5 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<%
color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense,d.Valeur_Depense2,d.Valeur_Depense3,d.Valeur_Depense4,d.Valeur_Depense5" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 1 AND 2) AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
%>
bgcolor="#CCCCCC" <% end if%>class="v1"><%=RS2.Fields("Nom_TypeDepense")%>
<% color = color +1
RS2.MoveNext
loop
RS2.Close
%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense) as vRet"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 3 AND 10) AND d.Valeur_Depense <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% if RS.Fields("chUnite")<25 and RS.Fields("Categ")<>11 and RS.Fields("Categ")<>5 and RS.Fields("Categ")<>6 then%>
<% end if
RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense2) as vRet2"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 3 AND 10) AND d.Valeur_Depense2 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense3) as vRet3"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 3 AND 10) AND d.Valeur_Depense3 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense4) as vRet4"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 3 AND 10) AND d.Valeur_Depense4 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense5) as vRet5"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 3 AND 10) AND d.Valeur_Depense5 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% if RS.Fields("chUnite")<25 and RS.Fields("Categ")<>11 and RS.Fields("Categ")<>5 and RS.Fields("Categ")<>6 then%>
<% RS2.Close%>
<% color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense,d.Valeur_Depense2,d.Valeur_Depense3,d.Valeur_Depense4,d.Valeur_Depense5" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 3 AND 10) AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
%>
bgcolor="#CCCCCC" <% end if%>class="v1"><%=RS2.Fields("Nom_TypeDepense")%>
<% if RS.Fields("chUnite")<25 and RS.Fields("Categ")<>11 and RS.Fields("Categ")<>5 and RS.Fields("Categ")<>6 then%>
<%
color = color +1
RS2.MoveNext
loop
RS2.Close
%>
<% Dim depGest
depGest = 0
strSQL = " SELECT d.Valeur_Depense5" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE t.Rang_Depense = 8 AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
if not isNull(RS2.Fields("Valeur_Depense5"))and RS2.Fields("Valeur_Depense5")<>111111 then
depGest = RS2.Fields("Valeur_Depense5")
end if
RS2.Close
%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense) as vRet"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 11 and 16) AND d.Valeur_Depense <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense2) as vRet2"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 11 and 16) AND d.Valeur_Depense2 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense3) as vRet3"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 11 and 16) AND d.Valeur_Depense3 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense4) as vRet4"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 11 and 16) AND d.Valeur_Depense4 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense5) as vRet5"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 11 and 16) AND d.Valeur_Depense5 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<%
color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense,d.Valeur_Depense2,d.Valeur_Depense3,d.Valeur_Depense4,d.Valeur_Depense5" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 11 and 16) AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
%>
bgcolor="#CCCCCC" <% end if%> class="v1"><%=RS2.Fields("Nom_TypeDepense")%>
<%
color = color +1
RS2.MoveNext
loop
RS2.Close
%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense) as vRet"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 17 and 22) AND d.Valeur_Depense <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense2) as vRet2"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 17 and 22) AND d.Valeur_Depense2 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense3) as vRet3"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 17 and 22) AND d.Valeur_Depense3 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense4) as vRet4"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 17 and 22) AND d.Valeur_Depense4 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense5) as vRet5"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 17 and 22) AND d.Valeur_Depense5 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<%
color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense,d.Valeur_Depense2,d.Valeur_Depense3,d.Valeur_Depense4,d.Valeur_Depense5" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 17 and 22) AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
%>
bgcolor="#CCCCCC" <% end if%> class="v1"><%=RS2.Fields("Nom_TypeDepense")%>
<%
color = color +1
RS2.MoveNext
loop
RS2.Close
%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense) as vRet"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 23 and 32) AND d.Valeur_Depense <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense2) as vRet2"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 23 and 32) AND d.Valeur_Depense2 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense3) as vRet3"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 23 and 32) AND d.Valeur_Depense3 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense4) as vRet4"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 23 and 32) AND d.Valeur_Depense4 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense5) as vRet5"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 23 and 32) AND d.Valeur_Depense5 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<%
color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense,d.Valeur_Depense2,d.Valeur_Depense3,d.Valeur_Depense4,d.Valeur_Depense5" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 23 and 32) AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
%>
bgcolor="#CCCCCC" <% end if%> class="v1"><%=RS2.Fields("Nom_TypeDepense")%>
<%
color = color +1
RS2.MoveNext
loop
RS2.Close
%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense) as vRet"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 33 and 36) AND d.Valeur_Depense <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense2) as vRet2"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 32 and 36) AND d.Valeur_Depense2 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense3) as vRet3"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 32 and 36) AND d.Valeur_Depense3 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense4) as vRet4"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 32 and 36) AND d.Valeur_Depense4 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense5) as vRet5"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 32 and 36) AND d.Valeur_Depense5 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<%
color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense,d.Valeur_Depense2,d.Valeur_Depense3,d.Valeur_Depense4,d.Valeur_Depense5" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 33 and 36) AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
%>
bgcolor="#CCCCCC" <% end if%> class="v1"><%=RS2.Fields("Nom_TypeDepense")%>
<%
color = color +1
RS2.MoveNext
loop
RS2.Close
%>
<% dim vd
color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense,d.Valeur_Depense2,d.Valeur_Depense3,d.Valeur_Depense4,d.Valeur_Depense5" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE t.Rang_Depense = 37 AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
if RS2.Fields("Valeur_Depense") = 111111 then vd =0 else vd = RS2.Fields("Valeur_Depense") %>
<%
color = color +1
RS2.MoveNext
loop
RS2.Close
%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense) as vRet"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 38 and 41) AND d.Valeur_Depense <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense2) as vRet2"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 38 and 41) AND d.Valeur_Depense2 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense3) as vRet3"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 38 and 41) AND d.Valeur_Depense3 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense4) as vRet4"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 38 and 41) AND d.Valeur_Depense4 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense5) as vRet5"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 38 and 41) AND d.Valeur_Depense5 <> 111111 AND d.ID_Listing = " & vID, CNRS
%>
<% RS2.Close%>
<%
color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense,d.Valeur_Depense2,d.Valeur_Depense3,d.Valeur_Depense4,d.Valeur_Depense5" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 38 and 41) AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
%>
bgcolor="#CCCCCC" <% end if%> class="v1"><%=RS2.Fields("Nom_TypeDepense")%>
<%
color = color +1
RS2.MoveNext
loop
RS2.Close
%>
<%
color = 0
strSQL = " SELECT t.Nom_TypeDepense, d.Valeur_Depense,d.Valeur_Depense2,d.Valeur_Depense3,d.Valeur_Depense4,d.Valeur_Depense5" & _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE t.Rang_Depense = 42 AND d.ID_Listing = " & vID & _
" ORDER BY t.Rang_Depense ASC"
RS2.Open strSQL, CNRS
do while not RS2.EOF
if RS2.Fields("Valeur_Depense") = 111111 then vd =0 else vd = RS2.Fields("Valeur_Depense") %>
<%
color = color +1
RS2.MoveNext
loop
RS2.Close
%>
<% dim vRet,vRet2,vRet3,vRet4,vRet5
if ( RS.Fields("chUnite")<25 and RS.Fields("Categ")<>11 and RS.Fields("Categ")<>5 and RS.Fields("Categ")<>6) then
RS2.Open " SELECT SUM (d.Valeur_Depense) as vRet"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 1 and 42) and t.ID_TypeDepense not in (4,61,59,60,37,26) AND d.Valeur_Depense <> 111111 AND d.ID_Listing = " & vID, CNRS
vRet = RS2.Fields("vRet")
else
RS2.Open " SELECT SUM (d.Valeur_Depense) as vRet"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 1 and 42) AND d.Valeur_Depense <> 111111 AND d.ID_Listing = " & vID, CNRS
vRet = RS2.Fields("vRet")
end if %>
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense2) as vRet2"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 1 and 42) AND d.Valeur_Depense2 <> 111111 AND d.ID_Listing = " & vID, CNRS
vRet2 = RS2.Fields("vRet2") %>
<%=PN(FormatNumber(PN4(vRet2), 0, , , true))%>$
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense3) as vRet3"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 1 and 42) AND d.Valeur_Depense3 <> 111111 AND d.ID_Listing = " & vID, CNRS
vRet3 = RS2.Fields("vRet3") %>
<%=PN(FormatNumber(PN4(vRet3) , 0, , , true))%>$
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense4) as vRet4"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 1 and 42) AND d.Valeur_Depense4 <> 111111 AND d.ID_Listing = " & vID, CNRS
vRet4 = RS2.Fields("vRet4") %>
<%=PN(FormatNumber(PN4(vRet4), 0, , , true))%>$
<% RS2.Close%>
<% RS2.Open " SELECT SUM (d.Valeur_Depense5) as vRet5"& _
" FROM tblDepense AS d INNER JOIN tblTypeDepense AS t ON d.ID_TypeDepense = t.ID_TypeDepense" & _
" WHERE (t.Rang_Depense BETWEEN 1 and 42) AND d.Valeur_Depense5 <> 111111 AND d.ID_Listing = " & vID, CNRS
vRet5 = RS2.Fields("vRet5") %>
<%Dim vac,vac2,vac3,vac4,vac5
vac = (vact*RDB/100)+ RDB_AR+ RDB_AR2
vac2 = RS.Fields("moVacDep2")+RDB_AR+ RDB_AR2
vac3 = RS.Fields("moVacDep3")+RDB_AR+ RDB_AR2
vac4 = RS.Fields("moVacDep4")+RDB_AR+ RDB_AR2
vac5 = (vact*RDB/100)+RDB_AR+ RDB_AR2
if RS.Fields("moRevenuBrut2")=111111 then vac2 = 111111 end if
if RS.Fields("moRevenuBrut3")=111111 then vac3 = 111111 end if
if RS.Fields("moRevenuBrut4")=111111 then vac4 = 111111 end if
%>
<%Dim revN,rev2,rev3,rev4,rev5
revN = RS.Fields("moRevenuBrut")+RDB_AR+ RDB_AR2-vRet-vac
rev2 = RS.Fields("moRevenuBrut2")+RDB_AR+ RDB_AR2-vRet2-vac2
rev3 = RS.Fields("moRevenuBrut3")+RDB_AR+ RDB_AR2-vRet3-vac3
rev4 = RS.Fields("moRevenuBrut4")+RDB_AR+ RDB_AR2-vRet4-vac4
rev5 = RS.Fields("moRevenuBrut5")+RDB_AR+ RDB_AR2-vRet5-vac5
if RS.Fields("moRevenuBrut")=111111 then revN = 111111 end if
if RS.Fields("moRevenuBrut2")=111111 then rev2 = 111111 end if
if RS.Fields("moRevenuBrut3")=111111 then rev3 = 111111 end if
if RS.Fields("moRevenuBrut4")=111111 then rev4 = 111111 end if
if RS.Fields("moRevenuBrut5")=111111 then rev5 = 111111 end if
%>
<%dim nrlignes
nrlignes = 0
if RS.Fields("chUnite")<25 and RS.Fields("Categ")<>11 and RS.Fields("Categ")<>5 and RS.Fields("Categ")<>6 then%>
Remarques : pour les résidences de 25 unités et moins excluant les CHSLD
Les salaires du propriétaire et des employés sont exclus dans le calcul des dépenses
Les salaires des employés sont inscrits à titre indicatif
C'est à l’acheteur d’inclure les salaires dans son calcul des dépenses
<%
nrLignes = nrLignes +4
end if %>
*La colonne (Ancienneté/ans) affiche l’ancienneté des employés selon les normes du travail, soit :
Durée du service continu
Durée des vacances
Indemnité
Délai entre l’avis et le départ
Moins d’un an
1 jour par mois complet de service continu sans excéder 2 semaines
4%
3 mois à un an
4%
Une semaine
1 an à moins de 5 ans
2 semaines continues
4%
2 semaines
5 à 10 ans
3 semaines continues
6%
4 semaines
10 ans et plus
3 semaines continues
6%
8 semaines
*Pour information, le taux du salaire minimum est actuellement de 9,65 $ l'heure (1 MAI 2011)
<%nrLignes = nrLignes +10 %>
<%=SautPage(nrLignes,nrSal,nrPage) %>
<%
dim nrSal, SalTot,NrEmp,VacTot,dir,cuis,inf,prep,prepS,prepN,Recept,entr,anim,compt,men,buand,totHeures,totHeuresPaies,nrPage,dateAncien,Autres,formation
totHeuresPaies = 0
totHeures = 0
dir =0
cuis =0
inf=0
prep=0
prepS=0
prepN=0
Recept=0
entr=0
anim=0
compt=0
men=0
buand=0
Autres=0
NrEmp =1
SalTot = 0
VacTot =0
dim totHeuresCuis,totHeuresPaiesCuis,VacTotCuis,SalTotCuis
totHeuresCuis=0
totHeuresPaiesCuis=0
VacTotCuis=0
SalTotCuis=0
nrPage = 2
strSQL = " SELECT distinct Formation" & _
" FROM tblSalaires" & _
" WHERE ID_Listing = " & vID
RS2.Open strSQL, CNRS
formation = RS2.Fields(0)
RS2.Close
strSQL = " SELECT Count(*) AS nrSal" & _
" FROM tblSalaires" & _
" WHERE (Titre = '0' OR Titre = '1' OR Titre = '2' ) and ID_Listing = " & vID
RS2.Open strSQL, CNRS
nrSal = RS2.Fields(0)
RS2.Close
if nrSal > 0 then
nrLignes = nrLignes +4
%>
<% dim form1,form2,form3,formTot
form3 = (formation mod 100) mod 10
form2 = ((formation mod 100) - form3)/10
form1 = (formation - form2*10 - form3)/100
formTot = ""
if form1=1 then
formTot = formTot &" MAPAQ;"
end if
if form2=1 then
formTot = formTot & " PDSB-RCR;"
end if
if form3=1 then
formTot = formTot & " PAB;"
end if%>
*Ancienneté/ans
#
Hr/s
Taux
Vac.
Annuel
DIRECTION
<%
color = 1
strSQL = " SELECT Titre,Heures,Taux,Annuel,Nombre,Vacance,Date_Ancien " & _
" FROM tblSalaires" & _
" WHERE (Titre = '0' OR Titre = '1' OR Titre = '2' ) and ID_Listing = " & vID & _
" ORDER BY Titre ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
%>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt"><%=FormatNumber(color * MD, 0, , , true)%>.
<% if RS2.Fields("Titre") = 1 then Response.Write "Directeur" end if
if RS2.Fields("Titre") = 2 then Response.Write "Directeur adjoint " end if
if RS2.Fields("Titre") = 0 then Response.Write "Propriétaire-gestionnaire " end if %>
<%dateAncien = RS2.Fields("Date_Ancien") %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
<% if RS2.Fields("Nombre") > 0 and Year(dateAncien) > 1900 then %>
<%=DifAnne(Year(Date())-Year(dateAncien)) %>
<%elseif RS2.Fields("Titre") <> 0 then%>
?<%end if %>
<%
dim totHeuresCompt,totHeuresPaiesCompt,VacTotCompt,SalTotCompt
totHeuresCompt=0
totHeuresPaiesCompt=0
VacTotCompt=0
SalTotCompt=0
strSQL = " SELECT Count(*) AS nrSal" & _
" FROM tblSalaires" & _
" WHERE (Titre BETWEEN '11' AND '12') and ID_Listing = " & vID
RS2.Open strSQL, CNRS
nrSal = RS2.Fields(0)
RS2.Close
if nrSal > 0 then
nrLignes = nrLignes +3
%>
<%=SautPage(nrLignes,nrSal,nrPage) %>
COMPTABILITÉ
<%
color = 1
strSQL = " SELECT Titre,Heures,Taux,Annuel,Nombre,Vacance,Date_Ancien " & _
" FROM tblSalaires" & _
" WHERE (Titre BETWEEN '11' AND '12') and ID_Listing = " & vID & _
" ORDER BY Titre ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
%>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt"><%=FormatNumber(color * MD, 0, , , true)%>.
<% if RS2.Fields("Titre") = 11 then Response.Write "Comptable" end if
if RS2.Fields("Titre") = 12 then Response.Write "Commis comptable" end if %>
<%dateAncien = RS2.Fields("Date_Ancien") %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
<% if RS2.Fields("Nombre") > 0 and Year(dateAncien) > 1900 then %>
<%=DifAnne(Year(Date())-Year(dateAncien)) %>
<%else %>?<%end if %>
<% end if %>
<% dim totHeuresInf,totHeuresPaiesInf,VacTotInf,SalTotInf
totHeuresInf=0
totHeuresPaiesInf=0
VacTotInf=0
SalTotInf=0
strSQL = " SELECT Count(*) AS nrSal" & _
" FROM tblSalaires" & _
" WHERE (Titre BETWEEN '3' AND '4') and ID_Listing = " & vID
RS2.Open strSQL, CNRS
nrSal = RS2.Fields(0)
RS2.Close
if nrSal > 0 then
nrLignes = nrLignes +3
%>
<%=SautPage(nrLignes,nrSal,nrPage) %>
SOINS INFIRMIERS
<%
color = 1
strSQL = " SELECT Titre,Heures,Taux,Annuel,Nombre,Vacance,Date_Ancien " & _
" FROM tblSalaires" & _
" WHERE (Titre BETWEEN '3' AND '4') and ID_Listing = " & vID & _
" ORDER BY Titre ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
%>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt"><%=FormatNumber(color * MD, 0, , , true)%>.
<% if RS2.Fields("Titre") = 3 then Response.Write "Licenciée" end if
if RS2.Fields("Titre") = 4 then Response.Write "Auxiliaire" end if%>
<%dateAncien = RS2.Fields("Date_Ancien") %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
<% if RS2.Fields("Nombre") > 0 and Year(dateAncien) > 1900 then %>
<%=DifAnne(Year(Date())-Year(dateAncien)) %> <%else %>?<%end if %>
<%end if %>
<%
dim totHeuresPrep,totHeuresPaiesPrep,VacTotPrep,SalTotPrep,nrPrep
totHeuresPrep=0
totHeuresPaiesPrep=0
VacTotPrep=0
SalTotPrep=0
nrPrep=0
strSQL = " SELECT Count(*) AS nrSal" & _
" FROM tblSalaires" & _
" WHERE (Titre BETWEEN '7' AND '9') and ID_Listing = " & vID
RS2.Open strSQL, CNRS
nrSal = RS2.Fields(0)
RS2.Close
if nrSal > 0 then
nrLignes = nrLignes +3
%>
<%if nrSal+nrLignes > 50 then%>
<%
nrPrep = 49 - nrLignes
%>
PRÉPOSÉ
<%
color = 1
strSQL = " SELECT Titre,Heures,Taux,Annuel,Nombre,Vacance,Date_Ancien " & _
" FROM tblSalaires" & _
" WHERE (Titre BETWEEN '7' AND '9') and ID_Listing = " & vID & _
" ORDER BY Titre ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
if color<=nrPrep then %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt"><%=FormatNumber(color * MD, 0, , , true)%>.
<% %>
<%
if RS2.Fields("Titre") = 7 then
prep = prep + RS2.Fields("Nombre")
Response.Write "Préposé-jour"
end if
if RS2.Fields("Titre") = 8 then
prepS = prepS + RS2.Fields("Nombre")
Response.Write "Préposé-soir"
end if
if RS2.Fields("Titre") = 9 then
prepN = prepN + RS2.Fields("Nombre")
Response.Write "Préposé-nuit"
end if %>
<%dateAncien = RS2.Fields("Date_Ancien") %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
<% if RS2.Fields("Nombre") > 0 and Year(dateAncien) > 1900 then %>
<%=DifAnne(Year(Date())-Year(dateAncien)) %> <%else %>?<%end if %>
<%
color = 1
strSQL = " SELECT Titre,Heures,Taux,Annuel,Nombre,Vacance,Date_Ancien " & _
" FROM tblSalaires" & _
" WHERE (Titre BETWEEN '7' AND '9') and ID_Listing = " & vID & _
" ORDER BY Titre ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
if color > nrPrep then %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt"><%=FormatNumber(color * MD, 0, , , true)%>.
<% %>
<%
if RS2.Fields("Titre") = 7 then
prep = prep + RS2.Fields("Nombre")
Response.Write "Préposé-jour"
end if
if RS2.Fields("Titre") = 8 then
prepS = prepS + RS2.Fields("Nombre")
Response.Write "Préposé-soir"
end if
if RS2.Fields("Titre") = 9 then
prepN = prepN + RS2.Fields("Nombre")
Response.Write "Préposé-nuit"
end if %>
<%dateAncien = RS2.Fields("Date_Ancien") %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
<% if RS2.Fields("Nombre") > 0 and Year(dateAncien) > 1900 then %>
<%=DifAnne(Year(Date())-Year(dateAncien)) %> <%else %>?<%end if %>
<%
color = 1
strSQL = " SELECT Titre,Heures,Taux,Annuel,Nombre,Vacance,Date_Ancien " & _
" FROM tblSalaires" & _
" WHERE (Titre BETWEEN '7' AND '9') and ID_Listing = " & vID & _
" ORDER BY Titre ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
%>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt"><%=FormatNumber(color * MD, 0, , , true)%>.
<% %>
<%
if RS2.Fields("Titre") = 7 then
prep = prep + RS2.Fields("Nombre")
Response.Write "Préposé-jour"
end if
if RS2.Fields("Titre") = 8 then
prepS = prepS + RS2.Fields("Nombre")
Response.Write "Préposé-soir"
end if
if RS2.Fields("Titre") = 9 then
prepN = prepN + RS2.Fields("Nombre")
Response.Write "Préposé-nuit"
end if %>
<%dateAncien = RS2.Fields("Date_Ancien") %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
<% if RS2.Fields("Nombre") > 0 and Year(dateAncien) > 1900 then %>
<%=DifAnne(Year(Date())-Year(dateAncien)) %> <%else %>?<%end if %>
<%end if %>
<%end if %>
<%
dim totHeuresRecept,totHeuresPaiesRecept,VacTotRecept,SalTotRecept
totHeuresRecept=0
totHeuresPaiesRecept=0
VacTotRecept=0
SalTotRecept=0
strSQL = " SELECT Count(*) AS nrSal" & _
" FROM tblSalaires" & _
" WHERE (Titre ='21') and ID_Listing = " & vID
RS2.Open strSQL, CNRS
nrSal = RS2.Fields(0)
RS2.Close
if nrSal > 0 then
nrLignes = nrLignes +3
%>
<%=SautPage(nrLignes,nrSal,nrPage) %>
RÉCEPTIONNISTE
<%
color = 1
strSQL = " SELECT Titre,Heures,Taux,Annuel,Nombre,Vacance,Date_Ancien " & _
" FROM tblSalaires" & _
" WHERE (Titre ='21') and ID_Listing = " & vID & _
" ORDER BY Titre ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
%>
<%end if %>
<%
dim totHeuresEntr,totHeuresPaiesEntr,VacTotEntr,SalTotEntr
totHeuresEntr=0
totHeuresPaiesEntr=0
VacTotEntr=0
SalTotEntr=0
strSQL = " SELECT Count(*) AS nrSal" & _
" FROM tblSalaires" & _
" WHERE (Titre ='10' OR Titre = '20') and ID_Listing = " & vID
RS2.Open strSQL, CNRS
nrSal = RS2.Fields(0)
RS2.Close
if nrSal > 0 then
nrLignes = nrLignes +3
%>
<%=SautPage(nrLignes,nrSal,nrPage) %>
ENTRETIEN
<%
color = 1
strSQL = " SELECT Titre,Heures,Taux,Annuel,Nombre,Vacance,Date_Ancien " & _
" FROM tblSalaires" & _
" WHERE (Titre ='10' OR Titre = '20') and ID_Listing = " & vID & _
" ORDER BY Titre ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
%>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt"><%=FormatNumber(color * MD, 0, , , true)%>.
<% if RS2.Fields("Titre") = 10 then Response.Write "Entretien" end if
if RS2.Fields("Titre") = 20 then Response.Write "Surintendant" end if%>
<%dateAncien = RS2.Fields("Date_Ancien") %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
<% if RS2.Fields("Nombre") > 0 and Year(dateAncien) > 1900 then %>
<%=DifAnne(Year(Date())-Year(dateAncien)) %>
<%else %>?<%end if %>
<%end if %>
<%
strSQL = " SELECT Count(*) AS nrSal" & _
" FROM tblSalaires" & _
" WHERE (Titre BETWEEN '5' AND '6') and ID_Listing = " & vID
RS2.Open strSQL, CNRS
nrSal = RS2.Fields(0)
RS2.Close
if nrSal > 0 then
nrLignes = nrLignes +3
%>
<%=SautPage(nrLignes,nrSal,nrPage) %>
CUISINE
<%
color = 1
strSQL = " SELECT Titre,Heures,Taux,Annuel,Nombre,Vacance,Date_Ancien " & _
" FROM tblSalaires" & _
" WHERE (Titre BETWEEN '5' AND '6') and ID_Listing = " & vID & _
" ORDER BY Titre ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
%>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt"><%=FormatNumber(color * MD, 0, , , true)%>.
<% if RS2.Fields("Titre") = 5 then Response.Write "Cuisinier" end if
if RS2.Fields("Titre") = 6 then Response.Write "Aide Cuisinier" end if %>
<%dateAncien = RS2.Fields("Date_Ancien") %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
<% if RS2.Fields("Nombre") > 0 and Year(dateAncien) > 1900 then %>
<%=DifAnne(Year(Date())-Year(dateAncien)) %> <%else %>?<%end if %>
<%end if %>
<%
dim totHeuresAnim,totHeuresPaiesAnim,VacTotAnim,SalTotAnim
totHeuresAnim=0
totHeuresPaiesAnim=0
VacTotAnim=0
SalTotAnim=0
strSQL = " SELECT Count(*) AS nrSal" & _
" FROM tblSalaires" & _
" WHERE Titre ='13' and ID_Listing = " & vID
RS2.Open strSQL, CNRS
nrSal = RS2.Fields(0)
RS2.Close
if nrSal > 0 then
nrLignes = nrLignes +3
%>
<%=SautPage(nrLignes,nrSal,nrPage) %>
ANIMATION
<%
color = 1
strSQL = " SELECT Titre,Heures,Taux,Annuel,Nombre,Vacance,Date_Ancien " & _
" FROM tblSalaires" & _
" WHERE Titre ='13' and ID_Listing = " & vID & _
" ORDER BY Titre ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
%>
<%end if %>
<%
dim totHeuresMen,totHeuresPaiesMen,VacTotMen,SalTotMen
totHeuresMen=0
totHeuresPaiesMen=0
VacTotMen=0
SalTotMen=0
strSQL = " SELECT Count(*) AS nrSal" & _
" FROM tblSalaires" & _
" WHERE (Titre BETWEEN '14' AND '16') and ID_Listing = " & vID
RS2.Open strSQL, CNRS
nrSal = RS2.Fields(0)
RS2.Close
if nrSal > 0 then
nrLignes = nrLignes +3
%>
<%=SautPage(nrLignes,nrSal,nrPage) %>
MÉNAGE
<%
color = 1
strSQL = " SELECT Titre,Heures,Taux,Annuel,Nombre,Vacance,Date_Ancien " & _
" FROM tblSalaires" & _
" WHERE (Titre BETWEEN '14' AND '16') and ID_Listing = " & vID & _
" ORDER BY Titre ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
%>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt"><%=FormatNumber(color * MD, 0, , , true)%>.
<% if RS2.Fields("Titre") = 14 then Response.Write "Ménage jour" end if
if RS2.Fields("Titre") = 15 then Response.Write "Ménage soir" end if
if RS2.Fields("Titre") = 16 then Response.Write "Ménage nuit" end if%>
<%dateAncien = RS2.Fields("Date_Ancien") %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
<% if RS2.Fields("Nombre") > 0 and Year(dateAncien) > 1900 then %>
<%=DifAnne(Year(Date())-Year(dateAncien)) %> <%else %>?<%end if %>
<% end if %>
<%
dim totHeuresBuand,totHeuresPaiesBuand,VacTotBuand,SalTotBuand
totHeuresBuand=0
totHeuresPaiesBuand=0
VacTotBuand=0
SalTotBuand=0
strSQL = " SELECT Count(*) AS nrSal" & _
" FROM tblSalaires" & _
" WHERE (Titre BETWEEN '17' AND '19') and ID_Listing = " & vID
RS2.Open strSQL, CNRS
nrSal = RS2.Fields(0)
RS2.Close
if nrSal > 0 then
nrLignes = nrLignes +3
%>
<%=SautPage(nrLignes,nrSal,nrPage) %>
BUANDERIE
<%
color = 1
strSQL = " SELECT Titre,Heures,Taux,Annuel,Nombre,Vacance,Date_Ancien " & _
" FROM tblSalaires" & _
" WHERE (Titre BETWEEN '17' AND '19') and ID_Listing = " & vID & _
" ORDER BY Titre ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
%>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt"><%=FormatNumber(color * MD, 0, , , true)%>.
<% if RS2.Fields("Titre") = 17 then Response.Write "Buanderie jour" end if
if RS2.Fields("Titre") = 18 then Response.Write "Buanderie soir" end if
if RS2.Fields("Titre") = 19 then Response.Write "Buanderie nuit" end if%>
<%dateAncien = RS2.Fields("Date_Ancien") %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
<% if RS2.Fields("Nombre") > 0 and Year(dateAncien) > 1900 then %>
<%=DifAnne(Year(Date())-Year(dateAncien)) %> <%else %>?<%end if %>
bgcolor="#CCCCCC" <% end if%> width="15%" class="texte-8pt">
<%=FormatNumber(VacTotBuand * MD, 0, , , true)%>$
bgcolor="#CCCCCC" <% end if%> width="10%" class="texte-8pt">
<%=FormatNumber(SalTotBuand * MD, 2, , , true)%>$
<%
color = color +1
end if %>
<%
dim totHeuresAutres,totHeuresPaiesAutres,VacTotAutres,SalTotAutres
totHeuresAutres=0
totHeuresPaiesAutres=0
VacTotAutres=0
SalTotAutres=0
strSQL = " SELECT Count(*) AS nrSal" & _
" FROM tblSalaires" & _
" WHERE (Titre BETWEEN '22' AND '25') and ID_Listing = " & vID
RS2.Open strSQL, CNRS
nrSal = RS2.Fields(0)
RS2.Close
if nrSal > 0 then
nrLignes = nrLignes +3
%>
<%=SautPage(nrLignes,nrSal,nrPage) %>
AUTRES SALAIRES
<%
color = 1
strSQL = " SELECT Titre,Heures,Taux,Annuel,Nombre,Vacance,Date_Ancien " & _
" FROM tblSalaires" & _
" WHERE (Titre BETWEEN '22' AND '25') and ID_Listing = " & vID & _
" ORDER BY Titre ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
%>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt"><%=FormatNumber(color * MD, 0, , , true)%>.
<% if RS2.Fields("Titre") = 22 then Response.Write "Autres #1 (voir notes)" end if
if RS2.Fields("Titre") = 23 then Response.Write "Autres #2 (voir notes)" end if
if RS2.Fields("Titre") = 24 then Response.Write "Autres #3 (voir notes)" end if
if RS2.Fields("Titre") = 25 then Response.Write "Autres #4 (voir notes)" end if%>
<%dateAncien = RS2.Fields("Date_Ancien") %>
bgcolor="#CCCCCC" <% end if%> class="texte-8pt">
<% if RS2.Fields("Nombre") > 0 and Year(dateAncien) > 1900 then %>
<%=DifAnne(Year(Date())-Year(dateAncien)) %> <%else %>?<%end if %>
<%end if %>
<%
dim totHeuresRed,totHeuresPaiesRed,VacTotRed,SalTotRed,Red
Red=0
totHeuresRed=0
totHeuresPaiesRed=0
VacTotRed=0
SalTotRed=0
strSQL = " SELECT Count(*) AS nrSal" & _
" FROM tblSalaires" & _
" WHERE (Titre ='26') and ID_Listing = " & vID
RS2.Open strSQL, CNRS
nrSal = RS2.Fields(0)
RS2.Close
if nrSal > 0 then
nrLignes = nrLignes +3
%>
<% if NrEmp<>0 then %>
<%=SautPage(nrLignes,20,nrPage) %>
<%if nrLignes<>0 then %>
Répartition des salaires
<%else %>
Répartition des salaires
<%end if %>
<% end if %>
<%
color = 1
strSQL = " SELECT Titre,Heures,Taux,Annuel,Nombre,Vacance,Date_Ancien " & _
" FROM tblSalaires" & _
" WHERE (Titre ='26') and ID_Listing = " & vID & _
" ORDER BY Titre ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
%>
<%
color = color +1
%>
<%
if RS.Fields("Ass")<>111 then Ass = SalTot * RS.Fields("Ass") /100 end if
Csst = red * RS.Fields("Csst") / 100
Fss = red *2.7 / 100
Rrq = red *4.95 / 100
Ase = red *1.4 / 100
Rqap = red *0.677 / 100
Cnt = red *0.08 / 100
TotTaux = Csst + Fss + Rrq + Ass + Ase + Rqap + Cnt
%>
<%if batiments > 1 or RS.Fields("dgNbrEtages")<>" " then %>
Niv.
<%end if %>
pi²
Tarifs
Soins
Total
Type
Sanitaire
Occupation
Aut.
H/F
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 OR RS.Fields("Categ")=4 then %>
B.
Cable
<% END IF %>
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 then %>
E.M.
S.
<%END IF %>
Date
Âge
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 OR RS.Fields("Categ")=4 then %>
<%else %>
<%end if %>
<% Dim Date_Bail,TarifPag,SoinPag,tar,soi,pcPag,hPag,fPag,fus,supFus,nrF,hfPag,pcTot,hfq
TarifPag =0
SoinPag=0
pcPag=0
hPag=0
fPag=0
fus=0
supFus=0
hfPag=0
pcTot=0
hfq=0
strSQL = " SELECT Chambre,Date_Loyers,Age,Superficie,Tarif,TypeL,Sanitaire,Vacante,Soin,Number2_Loyers,Bat,Fus,Balcon,HF,Station,Cable,ElMen,Niveau,Autonom,Autonom " & _
" FROM tblLoyers" & _
" WHERE Number2_Loyers > "& crt &" and Number2_Loyers < "& crt+54 &" and ID_Listing = " & vID &_
" ORDER BY Number2_Loyers ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
if RS2.Fields("Tarif")=111111 then tar = 0 else tar = RS2.Fields("Tarif") end if
if RS2.Fields("Soin")=111111 then soi = 0 else soi = RS2.Fields("Soin") end if
TarifPag =TarifPag + tar
SoinPag=SoinPag + soi
if RS2.Fields("Superficie")<>111111 then pcPag = pcPag + RS2.Fields("Superficie") end if
fus=RS2.Fields("Fus")
%>
bgcolor="#CCCCCC" <% end if%>>
<%=crt + 1 %>)
<%=RS2.Fields("Bat")%><%=RS2.Fields("Chambre")%>
<%if Len(RS2.Fields("Fus")) >0 then%>-<% end if%>
<%=fus%>
<%if batiments > 1 or RS.Fields("dgNbrEtages")<>" " then %>
<%if RS2.Fields("Niveau")>2 then %> <%=PN(RS2.Fields("Niveau")-2)%><% end if %>
<%if RS2.Fields("Niveau")= 2 then Response.Write "R-C" end if%>
<%if RS2.Fields("Niveau")= 1 then Response.Write "S-S" end if %>
<%if RS2.Fields("Niveau")= 0 then Response.Write "?" end if %>
<% end if %>
<%=PN(RS2.Fields("Superficie"))%>
<%if not isNull(fus) and len(fus)>0 then %>
<%
RS3.Open "SELECT COUNT (Superficie) AS nrF FROM tblLoyers WHERE Chambre = '"& fus &"' and ID_Listing = " & vID,CNRS
nrF = RS3.Fields("nrF")
RS3.Close
if nrF >0 then
RS3.Open "SELECT Superficie FROM tblLoyers WHERE Chambre = '"& fus &"' and ID_Listing = " & vID,CNRS
supFus= RS3.Fields("Superficie")%>
<%if supFus >0 then%>+<%=supFus%>
<% end if
supFus =0
RS3.Close
end if
end if%>
<%if RS2.Fields("Tarif")=111111 and RS2.Fields("Soin")=111111 then %>N/A
N/A
<%else %>
<%=PN(FormatNumber((soi+tar)* MD, 0, , , true))%>
<%end if %>$
<% if RS2.Fields("TypeL") = 0 then Response.Write "Chambre" end if
if RS2.Fields("TypeL") = 1 then Response.Write "Studio" end if
if RS2.Fields("TypeL") = 2 then Response.Write "Suite" end if
if RS2.Fields("TypeL") = 3 then Response.Write "1.1/2 fus" end if
if RS2.Fields("TypeL") = 4 then Response.Write "1 1/2" end if
if RS2.Fields("TypeL") = 5 then Response.Write "2 1/2" end if
if RS2.Fields("TypeL") = 6 then Response.Write "3 1/2" end if
if RS2.Fields("TypeL") = 7 then Response.Write "4 1/2" end if
if RS2.Fields("TypeL") = 8 then Response.Write "5 1/2" end if
if RS2.Fields("TypeL") = 9 then Response.Write "6 1/2" end if
if RS2.Fields("TypeL") = 10 then Response.Write "2.1/2 fus" end if
if RS2.Fields("TypeL") = 11 then Response.Write "2.1/2 fus" end if
if RS2.Fields("TypeL") = 12 then Response.Write "1 1/2 D" end if
if RS2.Fields("TypeL") = 13 then Response.Write "2 1/2 D" end if
if RS2.Fields("TypeL") = 14 then Response.Write "3 1/2 D" end if
if RS2.Fields("TypeL") = 15 then Response.Write "4 1/2 D" end if
if RS2.Fields("TypeL") = 16 then Response.Write "5 1/2 D" end if
if RS2.Fields("TypeL") = 17 then Response.Write "6 1/2 D" end if
%>
<% if RS2.Fields("Sanitaire") = 0 then Response.Write "Lavabo" end if
if RS2.Fields("Sanitaire") = 1 then Response.Write "L T" end if
if RS2.Fields("Sanitaire") = 2 then Response.Write "L T B/D" end if
if RS2.Fields("Sanitaire") = 3 then Response.Write "Lav.S-P" end if
if RS2.Fields("Sanitaire") = 4 then Response.Write "LT S-P" end if
if RS2.Fields("Sanitaire") = 5 then Response.Write "LTB S-P" end if
if RS2.Fields("Sanitaire") = 6 then Response.Write "L(p)/T(s-p)" end if
if RS2.Fields("Sanitaire") = 7 then Response.Write "?" end if
if RS2.Fields("Sanitaire") = 8 then Response.Write "[RIEN]" end if %>
<% if RS2.Fields("Vacante") = 0 then Response.Write "Privé" end if
if RS2.Fields("Vacante") = 1 then Response.Write "Vacante" end if
if RS2.Fields("Vacante") = 2 then Response.Write "Conv." end if
if RS2.Fields("Vacante") = 3 then Response.Write "R.I." end if
if RS2.Fields("Vacante") = 4 then Response.Write "A.P.ou A.S." end if
if RS2.Fields("Vacante") = 5 then Response.Write "R.T.F." end if
if RS2.Fields("Vacante") = 6 then Response.Write "Proprio" end if%>
<% if (RS2.Fields("Vacante")= 1 or RS2.Fields("Vacante") = 6) then%>N/A
<%elseif RS2.Fields("Vacante")= 2 then %>
<%else %>
<% if RS2.Fields("Autonom") = 0 then Response.Write "?" end if
if RS2.Fields("Autonom") = 1 then
redd=redd+1
%>
<% Response.Write "Na"%>
<% end if
if RS2.Fields("Autonom") = 2 then
redd=redd+1 %>
<% Response.Write "Na-z"%>
<%
end if
if RS2.Fields("Autonom") = 3 then
yel=yel+1 %>
<% Response.Write "S-m"%>
<%
end if
if RS2.Fields("Autonom") = 4 then
yel=yel+1 %>
<% Response.Write "Lp-a"%>
<%
end if
if RS2.Fields("Autonom") = 5 then
gren=gren+1 %>
<% Response.Write "Au."%>
<%
end if
if RS2.Fields("Autonom") = 6 then
Response.Write "inc."
end if
if RS2.Fields("Autonom") = 7 then Response.Write "N/A" end if%><%end if %>
<% if (RS2.Fields("Vacante")= 1 or RS2.Fields("Vacante") = 6) then%>
N/A
<% hfPag = hfPag +1
elseif RS2.Fields("Vacante")= 2 or RS2.Fields("Vacante") = 3 or RS2.Fields("Vacante") = 4 then %>N/A
<% hfPag = hfPag +1
else %>
<% if RS2.Fields("HF") = 0 then
Response.Write "?"
hfq = hfq +1
end if
if RS2.Fields("HF") = 1 then
Response.Write "H."
hPag=hPag+1
end if
if RS2.Fields("HF") = 2 then
Response.Write "F."
fPag=fPag+1
end if
if RS2.Fields("HF") = 3 then
Response.Write "H+F"
hPag=hPag+1
fPag=fPag+1
end if
if RS2.Fields("HF") = 4 then
Response.Write "N/A"
hfPag = hfPag +1
end if%><%end if %>
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 OR RS.Fields("Categ")=4 then %>
<% if RS2.Fields("Balcon") = 0 then Response.Write "?" end if
if RS2.Fields("Balcon") = 1 then
balc= balc+1
Response.Write "OUI"
end if
if RS2.Fields("Balcon") = 2 then Response.Write "NON" end if%>
<% if RS2.Fields("Cable") = 0 then Response.Write "?" end if
if RS2.Fields("Cable") = 1 then Response.Write "OUI/P" end if
if RS2.Fields("Cable") = 2 then Response.Write "OUI/L" end if
if RS2.Fields("Cable") = 3 then Response.Write "Partiel/P" end if
if RS2.Fields("Cable") = 4 then Response.Write "NON" end if%>
<% END IF %>
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 then %>
<% if RS2.Fields("TypeL") = 6 or RS2.Fields("TypeL") = 7 or RS2.Fields("TypeL") = 8 or RS2.Fields("TypeL") = 11 or RS2.Fields("TypeL") = 12 or RS2.Fields("TypeL") = 13 then%>
<% if RS2.Fields("ElMen") = 0 then Response.Write "?" end if
if RS2.Fields("ElMen") = 1 then Response.Write "NON" end if
if RS2.Fields("ElMen") = 2 then Response.Write "L-S" end if
if RS2.Fields("ElMen") = 3 then Response.Write "P-R" end if
if RS2.Fields("ElMen") = 4 then Response.Write "L-S/P-R" end if%>
<%else Response.Write "N/A" end if %>
<% if RS2.Fields("TypeL") = 6 or RS2.Fields("TypeL") = 7 or RS2.Fields("TypeL") = 8 or RS2.Fields("TypeL") = 11 or RS2.Fields("TypeL") = 12 or RS2.Fields("TypeL") = 13 then%>
<% if RS2.Fields("Station") = 0 then Response.Write "?" end if
if RS2.Fields("Station") = 1 then Response.Write "NON" end if
if RS2.Fields("Station") = 2 then Response.Write "Int." end if
if RS2.Fields("Station") = 3 then Response.Write "Ext." end if%> <%else Response.Write "Ext." end if %>
<% END IF %>
<%Date_Bail= RS2.Fields("Date_Loyers")%>
<% if (RS2.Fields("Vacante")= 1 or RS2.Fields("Vacante") = 6) then%>N/A
<%elseif RS2.Fields("Vacante")= 2 or RS2.Fields("Vacante") = 4 or RS2.Fields("Vacante") = 3 then %>N/A
<%else %>
<%if Year(Date_Bail) > 1900 then
anne = Right(Year(Date_Bail),2) %>
<%=Day(Date_Bail) %>/<%=Month(Date_Bail) %>/<%=anne %>
<%else %>?<%end if %>
<%end if %>
<% if (RS2.Fields("Vacante")= 2) then%>N/A<%else %> <%=RS2.Fields("Age")%><%end if %>
<%
crt = crt +1
RS2.MoveNext
loop
RS2.Close
%>
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 OR RS.Fields("Categ")=4 then %>
<%else %>
<%end if %>
#unité
<%if batiments > 1 or RS.Fields("dgNbrEtages")<>" " then %>
Niv.
<% end if %>
pi²
Tarifs
Soins
Total
Type
Sanitaire
Occupation
Aut.
H/F
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 OR RS.Fields("Categ")=4 then %>
B.
Cable
<% END IF %>
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 then %>
E.M.
S.
<%END IF %>
Date
#
<%=crt%>
<%if batiments > 1 or RS.Fields("dgNbrEtages")<>" " then %>
<%if batiments > 1 or RS.Fields("dgNbrEtages")<>" " then %>
Niv.
<%end if %>
pi²
Tarifs
Soins
Total
Type
Sanitaire
Occupation
Aut.
H/F
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 OR RS.Fields("Categ")=4 then %>
B.
Cable
<% END IF %>
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 then %>
E.M.
S.
<%END IF %>
Date
Âge
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 OR RS.Fields("Categ")=4 then %>
<%else %>
<%end if %>
<%
strSQL = " SELECT Chambre,Date_Loyers,Age,Superficie,Tarif,TypeL,Sanitaire,Vacante,Soin,Number2_Loyers,Bat,Fus,Balcon,HF,Station,Cable,ElMen,Niveau,Autonom " & _
" FROM tblLoyers" & _
" WHERE Number2_Loyers > "& crt &" and ID_Listing = " & vID &_
" ORDER BY Number2_Loyers ASC;"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF
if RS2.Fields("Tarif")=111111 then tar = 0 else tar = RS2.Fields("Tarif") end if
if RS2.Fields("Soin")=111111 then soi = 0 else soi = RS2.Fields("Soin") end if
TarifPag =TarifPag + tar
SoinPag=SoinPag + soi
if RS2.Fields("Superficie")<>111111 then pcPag = pcPag + RS2.Fields("Superficie") end if
fus=RS2.Fields("Fus")
%>
bgcolor="#CCCCCC" <% end if%>>
<%=crt + 1 %>)
<%=RS2.Fields("Bat")%><%=RS2.Fields("Chambre")%> <%if Len(RS2.Fields("Fus")) >0 then%>-<% end if%>
<%=RS2.Fields("Fus")%>
<%if batiments > 1 or RS.Fields("dgNbrEtages")<>" " then %>
<%if RS2.Fields("Niveau")>2 then %> <%=PN(RS2.Fields("Niveau")-2)%><% end if %>
<%if RS2.Fields("Niveau")= 2 then Response.Write "R-C" end if%>
<%if RS2.Fields("Niveau")= 1 then Response.Write "S-S" end if %>
<%if RS2.Fields("Niveau")= 0 then Response.Write "?" end if %>
<% end if %>
<%=PN(RS2.Fields("Superficie"))%>
<%if not isNull(fus) and len(fus)>0 then %>
<%
RS3.Open "SELECT COUNT (Superficie) AS nrF FROM tblLoyers WHERE Chambre = '"& fus &"' and ID_Listing = " & vID,CNRS
nrF = RS3.Fields("nrF")
RS3.Close
if nrF >0 then
RS3.Open "SELECT Superficie FROM tblLoyers WHERE Chambre = '"& fus &"' and ID_Listing = " & vID,CNRS
supFus= RS3.Fields("Superficie")%>
<%if supFus >0 then%>+<%=supFus%>
<% end if
supFus =0
RS3.Close
end if
end if%>
<%if RS2.Fields("Tarif")=111111 and RS2.Fields("Soin")=111111 then %>N/A
<%else %>
<%=PN(FormatNumber((soi+tar)* MD, 0, , , true))%>
<%end if %>
$
<% if RS2.Fields("TypeL") = 0 then Response.Write "Chambre" end if
if RS2.Fields("TypeL") = 1 then Response.Write "Studio" end if
if RS2.Fields("TypeL") = 2 then Response.Write "Suite" end if
if RS2.Fields("TypeL") = 3 then Response.Write "1.1/2 fus" end if
if RS2.Fields("TypeL") = 4 then Response.Write "1 1/2" end if
if RS2.Fields("TypeL") = 5 then Response.Write "2 1/2" end if
if RS2.Fields("TypeL") = 6 then Response.Write "3 1/2" end if
if RS2.Fields("TypeL") = 7 then Response.Write "4 1/2" end if
if RS2.Fields("TypeL") = 8 then Response.Write "5 1/2" end if
if RS2.Fields("TypeL") = 9 then Response.Write "6 1/2" end if
if RS2.Fields("TypeL") = 10 then Response.Write "2.1/2 fus" end if
if RS2.Fields("TypeL") = 11 then Response.Write "2.1/2 fus" end if
if RS2.Fields("TypeL") = 12 then Response.Write "1 1/2 D" end if
if RS2.Fields("TypeL") = 13 then Response.Write "2 1/2 D" end if
if RS2.Fields("TypeL") = 14 then Response.Write "3 1/2 D" end if
if RS2.Fields("TypeL") = 15 then Response.Write "4 1/2 D" end if
if RS2.Fields("TypeL") = 16 then Response.Write "5 1/2 D" end if
if RS2.Fields("TypeL") = 17 then Response.Write "6 1/2 D" end if
%>
<% if RS2.Fields("Sanitaire") = 0 then Response.Write "Lavabo" end if
if RS2.Fields("Sanitaire") = 1 then Response.Write "L T" end if
if RS2.Fields("Sanitaire") = 2 then Response.Write "L T B/D" end if
if RS2.Fields("Sanitaire") = 3 then Response.Write "Lav.S-P" end if
if RS2.Fields("Sanitaire") = 4 then Response.Write "LT S-P" end if
if RS2.Fields("Sanitaire") = 5 then Response.Write "LTB S-P" end if
if RS2.Fields("Sanitaire") = 6 then Response.Write "L(p)/T(s-p)" end if
if RS2.Fields("Sanitaire") = 7 then Response.Write "?" end if
if RS2.Fields("Sanitaire") = 8 then Response.Write "[RIEN]" end if %>
<% if RS2.Fields("Vacante") = 0 then Response.Write "Privé" end if
if RS2.Fields("Vacante") = 1 then Response.Write "Vacante" end if
if RS2.Fields("Vacante") = 2 then Response.Write "Conv." end if
if RS2.Fields("Vacante") = 3 then Response.Write "R.I." end if
if RS2.Fields("Vacante") = 4 then Response.Write "A.P.ou A.S." end if
if RS2.Fields("Vacante") = 5 then Response.Write "R.T.F." end if
if RS2.Fields("Vacante") = 6 then Response.Write "Proprio" end if%>
<% if (RS2.Fields("Vacante")= 1 or RS2.Fields("Vacante") = 6) then%>N/A
<%elseif RS2.Fields("Vacante")= 2 then %>
<%else %>
<% if RS2.Fields("Autonom") = 0 then Response.Write "?" end if
if RS2.Fields("Autonom") = 1 then
redd=redd+1
%>
<% Response.Write "Na"%>
<% end if
if RS2.Fields("Autonom") = 2 then
redd=redd+1 %>
<% Response.Write "Na-z"%>
<%
end if
if RS2.Fields("Autonom") = 3 then
yel=yel+1 %>
<% Response.Write "S-m"%>
<%
end if
if RS2.Fields("Autonom") = 4 then
yel=yel+1 %>
<% Response.Write "Lp-a"%>
<%
end if
if RS2.Fields("Autonom") = 5 then
gren=gren+1 %>
<% Response.Write "Au."%>
<%
end if
if RS2.Fields("Autonom") = 6 then
Response.Write "inc."
end if
if RS2.Fields("Autonom") = 7 then Response.Write "N/A" end if%><%end if %>
<% if (RS2.Fields("Vacante")= 1 or RS2.Fields("Vacante") = 6) then%>
N/A
<% hfPag = hfPag +1
elseif RS2.Fields("Vacante")= 2 or RS2.Fields("Vacante") = 3 or RS2.Fields("Vacante") = 4 then %>N/A
<% hfPag = hfPag +1
else %>
<% if RS2.Fields("HF") = 0 then
Response.Write "?"
hfq = hfq +1
end if
if RS2.Fields("HF") = 1 then
Response.Write "H."
hPag=hPag+1
end if
if RS2.Fields("HF") = 2 then
Response.Write "F."
fPag=fPag+1
end if
if RS2.Fields("HF") = 3 then
Response.Write "H+F"
hPag=hPag+1
fPag=fPag+1
end if
if RS2.Fields("HF") = 4 then
Response.Write "N/A"
hfPag = hfPag +1
end if%><%end if %>
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 OR RS.Fields("Categ")=4 then %>
<% if RS2.Fields("Balcon") = 0 then Response.Write "?" end if
if RS2.Fields("Balcon") = 1 then
balc= balc+1
Response.Write "OUI"
end if
if RS2.Fields("Balcon") = 2 then Response.Write "NON" end if%>
<% if RS2.Fields("Cable") = 0 then Response.Write "?" end if
if RS2.Fields("Cable") = 1 then Response.Write "OUI/P" end if
if RS2.Fields("Cable") = 2 then Response.Write "OUI/L" end if
if RS2.Fields("Cable") = 3 then Response.Write "Partiel/P" end if
if RS2.Fields("Cable") = 4 then Response.Write "NON" end if%>
<% END IF %>
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 then %>
<% if RS2.Fields("TypeL") = 6 or RS2.Fields("TypeL") = 7 or RS2.Fields("TypeL") = 8 or RS2.Fields("TypeL") = 11 or RS2.Fields("TypeL") = 12 or RS2.Fields("TypeL") = 13 then%>
<% if RS2.Fields("ElMen") = 0 then Response.Write "?" end if
if RS2.Fields("ElMen") = 1 then Response.Write "NON" end if
if RS2.Fields("ElMen") = 2 then Response.Write "L-S" end if
if RS2.Fields("ElMen") = 3 then Response.Write "P-R" end if
if RS2.Fields("ElMen") = 4 then Response.Write "L-S/P-R" end if%>
<%else Response.Write "N/A" end if %>
<% if RS2.Fields("TypeL") = 6 or RS2.Fields("TypeL") = 7 or RS2.Fields("TypeL") = 8 or RS2.Fields("TypeL") = 11 or RS2.Fields("TypeL") = 12 or RS2.Fields("TypeL") = 13 then%>
<% if RS2.Fields("Station") = 0 then Response.Write "?" end if
if RS2.Fields("Station") = 1 then Response.Write "NON" end if
if RS2.Fields("Station") = 2 then Response.Write "Int." end if
if RS2.Fields("Station") = 3 then Response.Write "Ext." end if%> <%else Response.Write "Ext." end if %>
<% END IF %>
<%Date_Bail= RS2.Fields("Date_Loyers")%>
<% if (RS2.Fields("Vacante")= 1 or RS2.Fields("Vacante") = 6 ) then%>N/A
<%elseif RS2.Fields("Vacante")= 2 or RS2.Fields("Vacante") = 4 then %>
<%else %>
<% if Year(Date_Bail) > 1900 then
anne = Right(Year(Date_Bail),2)%>
<%=Day(Date_Bail) %>/<%=Month(Date_Bail) %>/<%=anne %>
<%else %>?<%end if %>
<%end if %>
<% if (RS2.Fields("Vacante")= 2) then%>N/A<%else %> <%=RS2.Fields("Age")%><%end if %>
<%
crt = crt +1
RS2.MoveNext
loop
RS2.Close
%>
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 OR RS.Fields("Categ")=4 then %>
<%else %>
<%end if %>
#unité
<%if batiments > 1 or RS.Fields("dgNbrEtages")<>" " then %>
Niv.
<% end if %>
pi²
Tarifs
Soins
Total
Type
Sanitaire
Occupation
Aut.
H/F
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 OR RS.Fields("Categ")=4 then %>
B.
Cable
<% END IF %>
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 then %>
E.M.
S.
<%END IF %>
Date
#
<%=loyers%>
<%if batiments > 1 or RS.Fields("dgNbrEtages")<>" " then %>
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 OR RS.Fields("Categ")=4 then %>
<%=balc %>
<% balc=0
END IF %>
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 then %>
<% END IF %>
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 OR RS.Fields("Categ")=4 then %>
<%else %>
<%end if %>
Niv. = Niveau
, pi² = Superficie (pi²)
, B. = Balcon,
E.M. = Électroménagers,
S = Stationnement,
inc. = inconnue H/F = Homme+Femme/MAX.
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 OR RS.Fields("Categ")=4 then %>
<%else %>
<%end if %> Na=Non-autonome(+2h soins),Na-z=Alzheimer[<%=redd %>],
Sm=Santé-mentale,Lp-a=légère perte d'autonom.(1 à 2h soins)[<%=yel %>],
Au=autonome(1h soins)[<%=gren %>]
<%if RS.Fields("Categ")=1 OR RS.Fields("Categ")=2 OR RS.Fields("Categ")=4 then %>
<%else %>
<%end if %>
<%for I=7 to (50-restT)/2 %>
colspan="18"<%else %> colspan="14" <%end if %><%if I mod 3 = 1 then %> align="left" <%elseif I mod 3 = 2 then %> align="center" <%else%> align="right" <%end if %> >
<%if I mod 3 = 1 then %>ventilation des loyers<%end if %>
<%
RS2.Open " SELECT SUM (Tarif)" & _
" FROM tblLoyers" & _
" WHERE Tarif<>111111 AND ID_Listing = " & vID,CNRS
if not isNull(RS2.Fields(0)) and RS2.Fields(0)<> 0 then
T = RS2.Fields(0)
end if
RS2.Close
for J=1 to 7
%>
<% Dim Ix
RS2.Open " SELECT COUNT (Chambre) AS nrOc" & _
" FROM tblLoyers as l INNER JOIN tblLoyersOrdre AS v ON l.Vacante = v.Id_vacante" & _
" WHERE ordre = " & J & " AND ID_Listing = " & vID,CNRS
if RS2.Fields("nrOc") <> 0 then
RS3.Open " SELECT Id_vacante" & _
" FROM tblLoyersOrdre" & _
" WHERE ordre = " & J,CNRS
Ix= RS3.Fields("Id_vacante")
RS3.Close
%>
<%if Ix=0 then %>PRIVÉS<%end if %>
<%if Ix=1 then %>VACANTES<%end if %>
<%if Ix=2 then %> Conv.<%end if %>
<%if Ix=3 then %> R.I.<%end if %>
<%if Ix=4 then %> A.P. ou A.S.<%end if %>
<%if Ix=5 then %> R.T.F.<%end if %>
<%if Ix=6 then %>PROPRIO <%end if %>
<%if Ix=2 then %> <%end if %><%=Prct(RS2.Fields("nrOc"))%>
<% RS2.Close %>
<%
RS2.Open " SELECT SUM (Tarif)" & _
" FROM tblLoyers" & _
" WHERE Tarif<>111111 AND Vacante = " & I & " AND ID_Listing = " & vID,CNRS
%>
<%if not isNull(RS2.Fields(0)) then T1 = RS2.Fields(0) else T1=0 end if %>
<%if Ix=2 then %> <%end if %><%=Prct(FormatNumber(T1 * MD, 0, , , true))%> <%=SD%>
<% RS2.Close %>
<%if I=2 then %> <%end if %> (<%if vacantes = 0 then%>_<%end if %>
<%=Prct(FormatNumber(Div0(T1,T) * 100, 0, , , true))%>%)
<% RS2.Open " SELECT COUNT (TypeL) AS nrL,SUM (Tarif) AS TchS " & _
" FROM tblLoyers" & _
" WHERE Tarif<>111111 AND TypeL =0 AND Vacante = " & Ix & " AND ID_Listing = " & vID,CNRS
if RS2.Fields("nrL") > 0 then
%>
<% end if
RS2.Close%>
<% RS2.Open " SELECT COUNT (TypeL) AS nrL " & _
" FROM tblLoyers" & _
" WHERE (TypeL =3 or TypeL =10 or TypeL =11 ) AND Vacante = " & Ix & " AND ID_Listing = " & vID,CNRS
if RS2.Fields("nrL") > 0 then
%>
<%Response.Write "Avant-Fus."%>
<%=Prct(RS2.Fields("nrL"))%>
<% RS3.Open " SELECT SUM (Tarif) AS TchS " & _
" FROM tblLoyers" & _
" WHERE (TypeL =3 or TypeL =10 or TypeL =11 ) AND Vacante = " & Ix & " and Tarif<>111111 AND ID_Listing = " & vID,CNRS %>
<%RS3.Close
end if
RS2.Close%>
<%RS2.Open " SELECT COUNT (TypeL) AS nrL,SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =1 AND Vacante = " & Ix & " AND ID_Listing = " & vID,CNRS
if RS2.Fields("nrL") > 0 then
%>
<% end if
RS2.Close%>
<%RS2.Open " SELECT COUNT (TypeL) AS nrL,SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =4 AND Vacante = " & Ix & " AND ID_Listing = " & vID,CNRS
if RS2.Fields("nrL") > 0 then
%>
<% end if
RS2.Close%>
<%RS2.Open " SELECT COUNT (TypeL) AS nrL,SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =5 AND Vacante = " & Ix & " AND ID_Listing = " & vID,CNRS
if RS2.Fields("nrL") > 0 then
%>
<% end if
RS2.Close%>
<%RS2.Open " SELECT COUNT (TypeL) AS nrL,SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =6 AND Vacante = " & Ix & " AND ID_Listing = " & vID,CNRS
if RS2.Fields("nrL") > 0 then
%>
<%Response.Write "3.1/2"%>
<%=Prct(RS2.Fields("nrL"))%>
<% RS3.Open " SELECT SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =6 AND Vacante = " & Ix & " and Tarif<>111111 AND ID_Listing = " & vID,CNRS %>
<%if RS3.Fields("TS") then %>
<%end if %>
<% RS3.Close
end if
RS2.Close%>
<%RS2.Open " SELECT COUNT (TypeL) AS nrL,SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =7 AND Vacante = " & Ix & " AND ID_Listing = " & vID,CNRS
if RS2.Fields("nrL") > 0 then
%>
<% end if
RS2.Close%>
<%RS2.Open " SELECT COUNT (TypeL) AS nrL,SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =8 AND Vacante = " & Ix & " AND ID_Listing = " & vID,CNRS
if RS2.Fields("nrL") > 0 then
%>
<% end if
RS2.Close%>
<%RS2.Open " SELECT COUNT (TypeL) AS nrL,SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =9 AND Vacante = " & Ix & " AND ID_Listing = " & vID,CNRS
if RS2.Fields("nrL") > 0 then
%>
<%Response.Write "6.1/2"%>
<%=Prct(RS2.Fields("nrL"))%>
<% RS3.Open " SELECT SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =9 AND Vacante = " & Ix & " and Tarif<>111111 AND ID_Listing = " & vID,CNRS %>
<%if RS3.Fields("TS") then %>
<%end if %>
<% RS3.Close
end if
RS2.Close%>
<%RS2.Open " SELECT COUNT (TypeL) AS nrL,SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =12 AND Vacante = " & Ix & " AND ID_Listing = " & vID,CNRS
if RS2.Fields("nrL") > 0 then
%>
<% end if
RS2.Close%>
<%RS2.Open " SELECT COUNT (TypeL) AS nrL,SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =13 AND Vacante = " & Ix & " AND ID_Listing = " & vID,CNRS
if RS2.Fields("nrL") > 0 then
%>
<% end if
RS2.Close%>
<%RS2.Open " SELECT COUNT (TypeL) AS nrL,SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =14 AND Vacante = " & Ix & " AND ID_Listing = " & vID,CNRS
if RS2.Fields("nrL") > 0 then
%>
<%Response.Write "3.1/2 D"%>
<%=Prct(RS2.Fields("nrL"))%>
<% RS3.Open " SELECT SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =6 AND Vacante = " & Ix & " and Tarif<>111111 AND ID_Listing = " & vID,CNRS %>
<%if RS3.Fields("TS") then %>
<%end if %>
<% RS3.Close
end if
RS2.Close%>
<%RS2.Open " SELECT COUNT (TypeL) AS nrL,SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =15 AND Vacante = " & Ix & " AND ID_Listing = " & vID,CNRS
if RS2.Fields("nrL") > 0 then
%>
<% end if
RS2.Close%>
<%RS2.Open " SELECT COUNT (TypeL) AS nrL,SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =16 AND Vacante = " & Ix & " AND ID_Listing = " & vID,CNRS
if RS2.Fields("nrL") > 0 then
%>
<% end if
RS2.Close%>
<%RS2.Open " SELECT COUNT (TypeL) AS nrL,SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =17 AND Vacante = " & Ix & " AND ID_Listing = " & vID,CNRS
if RS2.Fields("nrL") > 0 then
%>
<%Response.Write "6.1/2 D"%>
<%=Prct(RS2.Fields("nrL"))%>
<% RS3.Open " SELECT SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =9 AND Vacante = " & Ix & " and Tarif<>111111 AND ID_Listing = " & vID,CNRS %>
<%if RS3.Fields("TS") then %>
<%end if %>
<% RS3.Close
end if
RS2.Close%>
<%RS2.Open " SELECT COUNT (TypeL) AS nrL,SUM (Tarif) AS TS " & _
" FROM tblLoyers" & _
" WHERE TypeL =2 AND Vacante = " & Ix & " AND ID_Listing = " & vID,CNRS
if RS2.Fields("nrL") > 0 then
%>
<%
RS2.Open " SELECT SUM (Soin)" & _
" FROM tblLoyers" & _
" WHERE Soin<>111111 and ID_Listing = " & vID,CNRS
%>
<% S =RS2.Fields(0)
if not IsNull(S)then
%>
<%Response.Write " Revenu Soins"%>
<%=FormatNumber(S * MD, 0, , , true)%> <%=SD%>
<%
else
S=0
end if
RS2.Close %>
<% dim loues
RS2.Open " SELECT COUNT (Chambre) AS nrOc" & _
" FROM tblLoyers" & _
" WHERE Vacante <>1 AND Vacante <>6 AND ID_Listing = " & vID,CNRS
loues= RS2.Fields("nrOc")
RS2.Close
%>
<%
if batiments > 1 then
Dim nomBat(2), nrBats
nrBats =0
strSQL = " SELECT Titre " & _
" FROM tblBatiment" & _
" WHERE ID_Listing = " & vID & " order by Titre ASC;"
RS2.Open strSQL, CNRS
do while not RS2.EOF
nomBat(nrBats) = RS2.Fields(0)
nrBats = nrBats +1
RS2.MoveNext
loop
RS2.Close %>
OCCUPATION PAR BÂTIMENT
Bâtiment
Unités
Revenu mensuel
<%
for I = 0 to Batiments-1
RS2.Open " SELECT Count (TypeL)" & _
" FROM tblLoyers" & _
" WHERE Bat = '" & nomBat(I) & "' and ID_Listing = " & vID,CNRS %>
1 then %> bgcolor="#CCCCCC" <% end if%>>
<%=nomBat(I)%>
<%=RS2.Fields(0) %>
<% RS2.Close
RS2.Open " SELECT SUM (Tarif)" & _
" FROM tblLoyers" & _
" WHERE Tarif<>111111 and Bat = '" & nomBat(I) & "' and ID_Listing = " & vID,CNRS %>
<%if isNull(RS2.Fields(0)) then %>?
<%else %>
<%=FormatNumber(RS2.Fields(0) * MD, 0, , , true)%> <%=SD%>
<%end if %>
<%RS2.Close
RS2.Open " SELECT SUM (Soin)" & _
" FROM tblLoyers" & _
" WHERE Soin<>111111 and Bat = '" & nomBat(I) & "' and ID_Listing = " & vID,CNRS
if not isNull(RS2.Fields(0)) or RS2.Fields(0)<>0 then
%>
1 then %> bgcolor="#CCCCCC" <% end if%>>
Soins :
<%if isNull(RS2.Fields(0)) then %>n/a
<%else %>
<%=FormatNumber(RS2.Fields(0) * MD, 0, , , true)%> <%=SD%>
<%end if %>
<%
end if
RS2.Close%>
<%
RS2.Open " SELECT COUNT (TypeL) AS nrL,SUM (Superficie) AS SL" & _
" FROM tblLoyers" & _
" WHERE (TypeL =1 ) AND ID_Listing = " & vID,CNRS
type_S = RS2.Fields("nrL")
if RS2.Fields("nrL") > 0 then
%>
<%end if %>
<% dim suploy
suploy =0
strSQL = " SELECT Count(*) AS no FROM tblSuperficieLoyers" & _
" WHERE ID_Listing = " & vID &_
";"
RS2.Open strSQL, CNRS
suploy = RS2.Fields("no")
RS2.Close
if suploy > 0 then %>
Groupe de superficies (pi² / m²)
Unités
<% strSQL = " SELECT Minim,Maxim,Unit " & _
" FROM tblSuperficieLoyers" & _
" WHERE ID_Listing = " & vID &_
";"
RS2.Open strSQL, CNRS
Do While Not RS2.EOF %>
<%
couleur = couleur +1
RS2.MoveNext
loop
RS2.Close
end if %>
SANITAIRES
<% Dim tSp
tSp=0
strSQL = " SELECT Count(*) AS noM FROM tblLoyers WHERE sanitaire=6 and ID_Listing = " & vID &_
";"
RS2.Open strSQL, CNRS
if not isnull(RS2.Fields(0)) then tSp = RS2.Fields(0) end if
RS2.Close
if batiments < 2 then
%>
<%end if %>
Unité
Lavabos
Toilettes
L+Toilettes
L+T+Bains
<%Response.Write "Privés"%>
<%=PN5(RS.Fields("chSaniPrive_L"))%><%if RS.Fields("chSaniPrive_L")<>0 then %>
(<%=FormatNumber(RS.Fields("chSaniPrive_L")/RS.Fields("chUnite") * 100, 0, , , true)%>%)
<%end if %>
---
<%=PN5(RS.Fields("chSaniPrive_LT"))%><%if RS.Fields("chSaniPrive_LT")<>0 then %>
(<%=FormatNumber(RS.Fields("chSaniPrive_LT")/RS.Fields("chUnite") * 100, 0, , , true)%>%)
<%end if %>
<%=PN5(RS.Fields("chSaniPrive_LTB"))%><%if RS.Fields("chSaniPrive_LTB")<>0 then %>
(<%=FormatNumber(RS.Fields("chSaniPrive_LTB")/RS.Fields("chUnite") * 100, 0, , , true)%>%)
<%end if %>
<%Response.Write "Semi-p."%>
<%=PN5(RS.Fields("chSaniSemiPrive_L"))%><%if RS.Fields("chSaniSemiPrive_L")<>0 then %>
(<%=FormatNumber(RS.Fields("chSaniSemiPrive_L")/RS.Fields("chUnite") * 100, 0, , , true)%>%) <%end if %>
<%=PN5(tSp) %>
<%=PN5(RS.Fields("chSaniSemiPrive_LT"))%><%if RS.Fields("chSaniSemiPrive_LT")<>0 then %>
(<%=FormatNumber(RS.Fields("chSaniSemiPrive_LT")/RS.Fields("chUnite") * 100, 0, , , true)%>%) <%end if %>
<%=PN5(RS.Fields("chSaniSemiPrive_LTB"))%><%if RS.Fields("chSaniSemiPrive_LTB")<>0 then %>
(<%=FormatNumber(RS.Fields("chSaniSemiPrive_LTB")/RS.Fields("chUnite") * 100, 0, , , true)%>%) <%end if %>
<%Response.Write "Public"%>
<%=PN5(RS.Fields("chSaniPublic_L"))%>
---
<%=PN5(RS.Fields("chSaniPublic_LT"))%>
<%=PN5(RS.Fields("chSaniPublic_LTB"))%>
NIVEAUX
<%
if batiments < 2 then
%>
<%end if %>
Niveau
Unités
Salle d'eau (bain public)
Salons
<% Dim Se,Sa,NomB,NomEt,TSe,Tsa,j
TSe=0
TSa=0
crt=0
for i = 0 to 17
Se=""
Sa=""
NomB =""
if i=0 then
NomEt = "?"
elseif i=2 then
NomEt = "R-C/1"
elseif i=3 then
NomEt = "1/R-C"
elseif i=1 then
NomEt = "S-S"
else
NomEt = i-2
end if
if batiments >1 then
for j = 0 to Batiments-1
RS2.Open " SELECT COUNT (TypeL) AS nrU " & _
" FROM tblLoyers" & _
" WHERE Niveau = "& i &" and Bat = '"& nomBat(j) &"' and ID_Listing = " & vID, CNRS
Un = RS2.Fields("nrU")
if RS2.Fields("nrU") > 0 then
strSQL = " SELECT Nr_SalleEau,Nr_Salons,NomBat " & _
" FROM tblEtages" & _
" WHERE NomEtage = '"& NomEt &"' and NomBat = '"& nomBat(j) &"' and ID_Listing = " & vID
RS3.Open strSQL, CNRS
if not RS3.EOF then
Se = RS3.Fields("Nr_SalleEau")
Sa = RS3.Fields("Nr_Salons")
if Se<>111111 then
TSe = TSe + RS3.Fields("Nr_SalleEau")
end if
if Sa<>111111 then
TSa = TSa + RS3.Fields("Nr_Salons")
end if
end if
RS3.Close
%>
<%if Un <>0 then %>
bgcolor="#CCCCCC" <% end if%>>
(<%=nomBat(j)%>)
<%=NomEt%>
<%=Un %>
<%=PNul(Se)%>
<%=PNul(Sa)%>
<%crt=crt+1
%>
<%end if %>
<% else
RS3.Open " SELECT Nr_SalleEau,Nr_Salons,NomBat " & _
" FROM tblEtages" & _
" WHERE NomEtage = '"& NomEt &"' and NomBat = '"& nomBat(j) &"' and ID_Listing = " & vID,CNRS
if not RS3.EOF then
Se = RS3.Fields("Nr_SalleEau")
Sa = RS3.Fields("Nr_Salons")
if Se<>111111 then
TSe = TSe + RS3.Fields("Nr_SalleEau")
end if
if Sa<>111111 then
TSa = TSa + RS3.Fields("Nr_Salons")
end if
%>
bgcolor="#CCCCCC" <% end if%>>
(<%=nomBat(j)%>)
<%=NomEt%>
<%=Un %>
<%=PNul(Se)%>
<%=PNul(Sa)%>
<%crt=crt+1 %>
<% end if
RS3.Close
end if
RS2.Close
next
else
RS2.Open " SELECT COUNT (TypeL) AS nrU " & _
" FROM tblLoyers" & _
" WHERE Niveau = "& i &" and ID_Listing = " & vID,CNRS
Un = RS2.Fields("nrU")
if RS2.Fields("nrU") > 0 then
RS3.Open " SELECT Nr_SalleEau,Nr_Salons,NomBat " & _
" FROM tblEtages" & _
" WHERE NomEtage = '"& NomEt &"' and ID_Listing = " & vID,CNRS
if not RS3.EOF then
Se = RS3.Fields("Nr_SalleEau")
Sa = RS3.Fields("Nr_Salons")
NomB = RS3.Fields("NomBat")
if Se<>111111 then
TSe = TSe + RS3.Fields("Nr_SalleEau")
end if
if Sa<>111111 then
TSa = TSa + RS3.Fields("Nr_Salons")
end if
end if
%>
<%if Un <>0 then %>
bgcolor="#CCCCCC" <% end if%>>
<%=NomEt%>
<%=Un %>
<%=PNul(Se)%>
<%=PNul(Sa)%>
<%crt=crt+1 %>
<%end if %>
<% RS3.Close
end if
RS2.Close
end if
next%>
<%
dim r1,r2,d1,hypo0,hypo1,hypCre,amm_0,amm_1,taux_0,taux_1,Clause,PretInit,Prime,Souscr,Date_Echeance,ID_Cre,schlR,compteTitre,estSc,ref,mf
hypo1=0
hypCre=0
amm_1=0
taux_1=0
r1=0
r2=0
schlR =0
Clause=0
PretInit=0
Prime=0
compteTitre = 0
Souscr= 0
Date_Echeance = 0
ID_Cre =0
estSc=0
ref =0
strSQL = " SELECT c.ID_TypePret,c.ID_TypeCreancier, t.Nom_TypeCreancier, c.Hypotheque_cre, c.Hypotheque2_cre, c.TauxInteret_cre, c.Mensuel_cre, c.Echeance_cre,"& _
" c.Amortissement_cre,c.Date_Client,c.Schl,c.Clause,c.PretInit,c.Prime,c.Date_Echeance,c.Souscr" & _
" FROM tblCreancier AS c LEFT JOIN tblTypeCreancier AS t ON c.ID_TypeCreancier = t.ID_TypeCreancier" & _
" WHERE c.ID_Listing = " & vID &" AND c.ID_TypePret = 1 "
RS2.Open strSQL, CNRS
do while not RS2.EOF
schlR = RS2.Fields("Schl")
if(RS2.Fields("Schl")) then estSc=1 end if
hypCre = RS2.Fields("Hypotheque_cre")
Prime=RS2.Fields("Prime")
Souscr= RS2.Fields("Souscr")
ID_Cre = RS2.Fields("ID_TypeCreancier")
if ID_Cre <>20 then
mf=RS.Fields("moPrix")-Balance -hypCre
else
mf=RS.Fields("moPrix") -hypCre
end if
%>
<% if (compteTitre = 0 or schlR or ref =20) then
if mf<>0 then
%>
Mise de fonds : <%=FormatNumber(mf * MD, 0, , , true)%> <%=SD%>
<%if ID_Cre=20 then %>(REFUSÉ)
<%end if %>
<%end if %>
colspan="11"<%else %>colspan="10"<%end if %> bgcolor="#CCCCCC" class="texte-7pt1">
Créancier
HYP-initiale
Ratio Hyp./Prix
<% if estSc=1 then%>
HYP + SCHL
<%end if %>
Intérêt
Mensualité
Annuel
Dû
Ans
Rembour /5ans
sement /10ans
colspan="11"<%else %>colspan="10"<%end if %> bgcolor="#CCCCCC" class="texte-9pt">
<%strSQL = " SELECT s.Clause,s.PretInit,s.Prime,s.Date_Echeance,s.Souscr,s.Hypotheque_cre" & _
" FROM tblCreancier AS s " & _
" WHERE s.ID_Listing = " & vID &" AND s.ID_TypePret = 1 and Schl = 1"
RS2.Open strSQL, CNRS
do while not RS2.EOF
hypCre = RS2.Fields("Hypotheque_cre")
Clause=RS2.Fields("Clause")
PretInit=RS2.Fields("PretInit")
Prime=RS2.Fields("Prime")
Souscr= RS2.Fields("Souscr")
Date_Echeance = RS2.Fields("Date_Echeance")
%>
colspan="11"<%else %>colspan="10"<%end if %> class="texte-9pt">
SCHL (Projeté)
1)HYP-initiale
:
<%=FormatNumber(PretInit * MD, 0, , , true)%> $
2)Prime SCHL
:
<%=FormatNumber(Prime * MD, 0, , , true)%>$ <% if PretInit <>0 then %>(<%=FormatNumber(Prime/PretInit * 100, 2, , , true)%>%)
<%end if %>
colspan="11"<%else %>colspan="10"<%end if %> bgcolor="#CCCCCC" class="texte-9pt">
colspan="11"<%else %>colspan="10"<%end if %> class="texte-9pt">
<%
dim Typ2
strSQL = " SELECT Count(*) AS type2" & _
" FROM tblCreancier" & _
" WHERE ID_Listing = " & vID & " AND ID_TypePret = 2"
RS2.Open strSQL, CNRS
Typ2 = RS2.Fields(0)
RS2.Close
if Typ2 > 0 then
%>
colspan="11"<%else %>colspan="10"<%end if %> class="texte-8ptS">
A-1) Balance de vente possible par le propriétaire actuel
<%
dim r12,r22,hyp0,hyp1,amm0,amm1,taux0,taux1
r12=0
r22=0
hyp1=0
amm1=0
taux1=0
strSQL = " SELECT c.ID_TypePret, t.Nom_TypeCreancier, c.Hypotheque_cre, c.Hypotheque2_cre, c.TauxInteret_cre, c.Mensuel_cre, c.Echeance_cre, c.Amortissement_cre" & _
" FROM tblCreancier AS c LEFT JOIN tblTypeCreancier AS t ON c.ID_TypeCreancier = t.ID_TypeCreancier" & _
" WHERE c.ID_Listing = " & vID &" AND c.ID_TypePret = 2"
RS2.Open strSQL, CNRS
do while not RS2.EOF %>
colspan="11"<%else %>colspan="10"<%end if %> bgcolor="#CCCCCC" class="texte-9pt">
colspan="5"<%else %>colspan="4"<%end if %> class="texte-8pt-titre">
Total paiement mensuel/annuel<% if Typ2 > 0 then%>(A + A-1)<%end if %>:
<%=FormatNumber(vVal2 * MD, 0, , , true)%> $
<%=FormatNumber((vVal2*12) * MD, 0, , , true)%> $
colspan="9"<%else %>colspan="8"<%end if %> class="texte-8pt-titre">
Remboursement moyen en capital payé par année :
<%=FormatNumber((r1 + r12) * MD, 0, , , true)%> $
<%=FormatNumber((r2 + r22) * MD, 0, , , true)%> $
<%for I=0 to 5 %>
colspan="18"<%else %> colspan="14" <%end if %><%if I mod 3 = 1 then %> align="left" <%elseif I mod 3 = 2 then %> align="center" <%else%> align="right" <%end if %> >
<%if I mod 3 = 1 then %>refinancement hypothécaire<%end if %>
<%next %>
<% end if %>
<%ShowProjection()%> / <%ShowDateP()%>
<%
dim Typ3
strSQL = " SELECT Count(*) AS typet" & _
" FROM tblCreancier" & _
" WHERE ID_Listing = " & vID & " AND ID_TypePret = 3"
RS2.Open strSQL, CNRS
Typ3 = RS2.Fields(0)
RS2.Close
if Typ3 > 0 then
%>
<%
dim Typ4,a,d2,finHyp1,finHypo0,finHypo1
strSQL = " SELECT Count(*) AS typeq" & _
" FROM tblCreancier" & _
" WHERE ID_Listing = " & vID & " AND ID_TypePret = 6"
RS2.Open strSQL, CNRS
Typ4 = RS2.Fields(0)
RS2.Close
dim Typ5
strSQL = " SELECT Count(*) AS typeq" & _
" FROM tblCreancier" & _
" WHERE ID_Listing = " & vID & " AND ID_TypePret = 5"
RS2.Open strSQL, CNRS
Typ5 = RS2.Fields(0)
RS2.Close
%>
<% Dim page2Ass
page2Ass=0
vVal = RS.Fields("notesAss")
if not isnull(vVal) then
if Len(vVal) > 10 then
page2Ass = 1%>
<% end if
end if %>
<%
Ar14 = Ar14 + CalculerRemb(RS2.Fields("Hypotheque_cre"), RS2.Fields("Amortissement_cre"),RS2.Fields("TauxInteret_cre"), 5)
Ar24 = Ar24 + CalculerRemb(RS2.Fields("Hypotheque_cre"), RS2.Fields("Amortissement_cre"),RS2.Fields("TauxInteret_cre"), 10)
Ar14Now = Ar14Now + CalculerRembNow(RS2.Fields("Hypotheque_cre"), RS2.Fields("Amortissement_cre"),RS2.Fields("TauxInteret_cre"),DateDiff("yyyy",RS2.Fields("Date_Solde"),RS2.Fields("Date_Client")),5)
Ar24Now = Ar24Now + CalculerRembNow(RS2.Fields("Hypotheque_cre"), RS2.Fields("Amortissement_cre"),RS2.Fields("TauxInteret_cre"),DateDiff("yyyy",RS2.Fields("Date_Solde"),RS2.Fields("Date_Client")),10)
Ad14 = RS2.Fields("Date_Client")
if Ad04 =0 then Ad04=Ad14 end if
Ahypo14=RS2.Fields("Hypotheque_cre")
if Ahypo04 =0 then Ahypo04=Ahypo14 end if
Aamm_14 = RS2.Fields("Amortissement_cre")
if Aamm_04 =0 then Aamm_04=Aamm_14 end if
Ataux_14= RS2.Fields("TauxInteret_cre")*100
if Ataux_04 =0 then Ataux_04=Ataux_14 end if
Anne14 = RS2.Fields("Date_Solde")
if Anne04 =0 then Anne0=Anne1 end if
RS2.MoveNext
loop
RS2.Close
%>
<%strSQL = " SELECT s.ID_cre, s.Clause,s.PretInit,s.Prime,s.Date_Echeance,s.Souscr,s.Hypotheque_cre,t.Nom_TypeCreancier,s.Date_Solde" & _
" FROM tblCreancier AS s,tblTypeCreancier AS t " & _
" WHERE s.ID_TypeCreancier = t.ID_TypeCreancier AND s.ID_Listing = " & vID &" AND s.ID_TypePret=3 and s.Schl = 1 ORDER BY s.Date_Client"
RS2.Open strSQL, CNRS
do while not RS2.EOF
hypCre = RS2.Fields("Hypotheque_cre")
Clause=RS2.Fields("Clause")
PretInit=RS2.Fields("PretInit")
Prime=RS2.Fields("Prime")
Souscr= RS2.Fields("Souscr")
Date_Echeance = RS2.Fields("Date_Echeance")
PretInitAs = PretInit -(Prime+Souscr)
cre_0 = RS2.Fields("Nom_TypeCreancier")
AnneB = RS2.Fields("Date_Solde")
%>
COÛT SCHL : <%=cre_0%>
<%if renouv1 = RS2.Fields("ID_cre") OR renouv2 = RS2.Fields("ID_cre") then%>
( Expirée et renouvelée )
<%end if %>
1)HYP-Solde/Date
:
<%=FormatNumber(PretInitAs * MD, 0, , , true)%> $
2)Prime SCHL
:
<%=FormatNumber(Prime * MD, 0, , , true)%>$ <% if PretInitAS <>0 then %>(<%=FormatNumber(Prime/PretInitAs * 100, 2, , , true)%>%)
<%end if %>
B-1) Balance de vente possible par le propriétaire actuel
<%
dim Ar12,Ar22,Ahyp0,Ahyp1,Aamm0,Aamm1,Ataux0,Ataux1
Ar12=0
Ar22=0
Ahyp1=0
Aamm1=0
Ataux1=0
strSQL = " SELECT c.ID_TypePret, t.Nom_TypeCreancier, c.Hypotheque_cre, c.Hypotheque2_cre, c.TauxInteret_cre, c.Mensuel_cre, c.Echeance_cre, c.Amortissement_cre" & _
" FROM tblCreancier AS c LEFT JOIN tblTypeCreancier AS t ON c.ID_TypeCreancier = t.ID_TypeCreancier" & _
" WHERE c.ID_Listing = " & vID &" AND c.ID_TypePret = 5"
RS2.Open strSQL, CNRS
do while not RS2.EOF
%>
_(*) Hypothèque initiale (**) Hypothèque en date d'acquisition projetée
2 then%> colspan="7"<% elseif Typ3 > 1 or Typ4 > 0 then%> colspan="6" <% else %> colspan="5" <% end if %> class="texte-8pt" align="center">
CALENDRIER HYPOTHÉCAIRE de mises de fonds necessaires selon la date d'acquisition projetée (6 Mois)
Mois
<% if Typ5 > 0 then%>
Balance de vente
<% end if %>
Prêt existant
<% if Typ3 > 1 then%>
Prêt existant
<% end if %>
<% if Typ3 > 2 then%>
Prêt existant
<% end if %>
Total existant
<% if Typ4 > 0 then %>
BV existant
<% end if %>
<% if Typ4 > 1 then %>
BV existant
<% end if %>
Comptant
2 then%> colspan="7"<% elseif Typ3 > 1 or Typ4 > 0 then%> colspan="6" <% else %> colspan="5" <% end if %> bgcolor="#990000">
<% dim P1,P2, BVe1,BVe2,d3,P3
P1=0
P2=0
P3=0
BVe1=0
BVe2=0
color=1
d1 = Ad0
d2 = Month(d1)
d3 = Year(d1)
for I=0 to 5 %>
bgcolor="#CCCCCC" <% end if%>>
<%if d2 +I <13 then %><%=Mid(MonthName(d2+I),1,2)%>(<%=d3 %>)<%end if %>
<% if d2 +I>12 and d2+I <25 then %><%=Mid(MonthName(d2+I-12),1,2)%>(<%=d3+1 %>)<%end if %>
<%if d2 +I>24 then %><%=Mid(MonthName(d2+I-24),1,2)%>(<%=d3+2 %>)<%end if %>
<%Dim norme1, norme2,RDF_norme1,RDF_norme2, rep1,prix
prix = RS.Fields("moPrix")
if RS.Fields("chUnite")>50 then
norme1 = 75
norme2 = 85
else
norme1 = 65
norme2 = 75
end if
RDF_norme1=0
RDF_norme2=0
if taux_1 <>0 then
RDF_norme1 = CalculerMensualite(norme1*RS.Fields("moPrix")/ 100,25,taux_1)*12
RDF_norme2 = CalculerMensualite(norme2*RS.Fields("moPrix")/ 100,25,taux_1)*12
end if
%>
<%
strSQL = "SELECT top 7 NomCcac FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
# <%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
2.
Unites
<%
strSQL = "SELECT top 7 Unites FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
3.
Prix ($)
<%
strSQL = "SELECT top 7 Prix FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
4.
Revenu brut (A) ($)
<%
strSQL = "SELECT top 7 RevBrut FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
5.
Vacantes ($)
<%
strSQL = "SELECT top 7 Vacantes FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
6.
Taxes ($)
<%
strSQL = "SELECT top 7 Taxes FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
7.
Salaires($)
<%
strSQL = "SELECT top 7 Salaires FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
8.
Autres depenses ($)
<%
strSQL = "SELECT top 7 Depenses FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
9.
Revenu net ($)
<%
strSQL = "SELECT top 7 RevNet FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
10.
TGA (Taux global d'actualisation)
<%
strSQL = "SELECT top 7 Tga FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
11.
MRN (Multiplicateur de revenu net)
<%
strSQL = "SELECT top 7 Mrn FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
12.
TRE (Net/comptant)
<%
strSQL = "SELECT top 7 Tre FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
13.
Ratio d'exploitation
<%
strSQL = "SELECT top 7 RatExpl FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
14.
Taux occupation
<%
strSQL = "SELECT top 7 TauxOcc FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>%
<%
RS3.MoveNext
loop
RS3.Close
%>
15.
Prix / Unité ($)
<%
strSQL = "SELECT top 7 PrixUnit FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
16.
Depenses / (100)pi² ($)
<%
strSQL = "SELECT top 7 depCentPi FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
17.
Salaires / Revenu brut (A)
<%
strSQL = "SELECT top 7 SalRev FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
18.
Revenu brut (A) / Unité ($)
<%
strSQL = "SELECT top 7 RevUnit FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
19.
MRB (Prix/Brut minimal)
<%
strSQL = "SELECT top 7 Mrb FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
20.
TRN (Net minimal/prix)
<%
strSQL = "SELECT top 7 Trn FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
21.
Taux vacance permis
<%
strSQL = "SELECT top 7 Tvp FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
22.
Ratio d'efficacité (superficies : unités/batiment)
<%
strSQL = "SELECT top 7 RatEff FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 1) ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%if RS3.Fields(0)<>0 then%>
<%= RS3.Fields(0)%>%
<% else %>Non-disp.<%end if %>
<%
RS3.MoveNext
loop
RS3.Close
%>
COMPARABLES VENDUS
1.
RÉSIDENCE
<%
strSQL = "SELECT top 7 NomCcac FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
# <%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
2.
Unites
<%
strSQL = "SELECT top 7 Unites FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
3.
DATE VENTE
<%
strSQL = "SELECT top 7 DateVente FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
4.
Prix ($)
<%
strSQL = "SELECT top 7 Prix FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
5.
Revenu brut (A) ($)
<%
strSQL = "SELECT top 7 RevBrut FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
6.
Vacantes ($)
<%
strSQL = "SELECT top 7 Vacantes FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
7.
Taxes ($)
<%
strSQL = "SELECT top 7 Taxes FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
8.
Salaires ($)
<%
strSQL = "SELECT top 7 Salaires FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
9.
Autres depenses ($)
<%
strSQL = "SELECT top 7 Depenses FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
10.
Revenu net ($)
<%
strSQL = "SELECT top 7 RevNet FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
11.
TGA (Taux global d'actualisation)
<%
strSQL = "SELECT top 7 Tga FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
12.
MRN (Multiplicateur de revenu net)
<%
strSQL = "SELECT top 7 Mrn FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
13.
TRE (Net/comptant)
<%
strSQL = "SELECT top 7 Tre FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
14.
Ratio d'exploitation
<%
strSQL = "SELECT top 7 RatExpl FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
15.
Taux occupation
<%
strSQL = "SELECT top 7 TauxOcc FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>%
<%
RS3.MoveNext
loop
RS3.Close
%>
16.
Prix / Unité ($)
<%
strSQL = "SELECT top 7 PrixUnit FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
17.
Depenses / (100)pi² ($)
<%
strSQL = "SELECT top 7 depCentPi FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
18.
Salaires / Revenu brut (A)
<%
strSQL = "SELECT top 7 SalRev FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
19.
Revenu brut (A) / Unité ($)
<%
strSQL = "SELECT top 7 RevUnit FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=FormatNumber(RS3.Fields(0), 0, , , true)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
20.
MRB (Prix/Brut minimal)
<%
strSQL = "SELECT top 7 Mrb FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
21.
TRN (Net minimal/prix)
<%
strSQL = "SELECT top 7 Trn FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
22.
Taux vacance permis
<%
strSQL = "SELECT top 7 Tvp FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%=RS3.Fields(0)%>
<%
RS3.MoveNext
loop
RS3.Close
%>
23.
Ratio d'efficacité (superficies : unités/batiment)
<%
strSQL = "SELECT top 7 RatEff FROM tblResidenceNet WHERE (Unites > "& unitBas &" and Unites < "& unitHaut &" ) AND (ID_Listing IN (SELECT ID_Listing FROM tblAccesWeb " &_
" WHERE (ID_ach = 1))) AND (MainVente = 0) ORDER BY DateVente desc ;"
RS3.Open strSQL, CNRS
Do While Not RS3.EOF
%>
<%if RS3.Fields(0)<>0 then%>
<%= RS3.Fields(0)%>%
<% else %>Non-disp.<%end if %>
<%
RS3.MoveNext
loop
RS3.Close
%>
<%ShowProjection()%> / <%ShowDateP()%>
<%else
SendEMail EMAIL_FROM, EMAIL_TO, "","Listing complet " & lettreVF(resId) & resId & lettreOpen(resId) &" (30 jours passés-visible: VOTRE SESSION A EXPIRÉ !!!) par l'ach. #" & ida & idn & " !!! ", " "
%>
<%if RS.Fields("Titre")=1 then %>RÉSIDENCE POUR PERSONNES AGÉES<%END IF %>
<%if RS.Fields("Titre")=2 then %>RESSOURCE INTERMEDIAIRE EN SANTÉ MENTALE<%END IF %>
<%if RS.Fields("Categ")=1 then %>Complexe d'appartement sans service<%END IF %>
<%if RS.Fields("Categ")=2 then %>Complexe d'appartement avec service<%END IF %>
<%if RS.Fields("Categ")=3 then %>Ressource intermediaire gerontologie<%END IF %>
<%if RS.Fields("Categ")=4 then %>Ressource intermediaire gerontologie<%END IF %>
<%if RS.Fields("Categ")=11 then %>CHSLD public<%END IF %>
<%if RS.Fields("Categ")=5 then %>CHSLD privé autofinancé<%END IF %>
<%if RS.Fields("Categ")=6 then %>CHSLD conventionné<%END IF %>
<%if RS.Fields("Categ")=7 then %>Clientele privé santé mentale<%END IF %>
<%if RS.Fields("Categ")=8 then %>Clientele privé en lourde perte d'autonomie<%END IF %>
<%if RS.Fields("Categ")=9 then %>Repas et services inclus<%END IF %>
<%if RS.Fields("Categ")=10 then %>Osbl<%END IF %>
<%if RS.Fields("SCateg1") then %>Chambres privées <%END IF %>
<%if RS.Fields("SCateg2") then %>Studios privés <%END IF %>
<%if RS.Fields("SCateg3") then %>Achat service<%END IF %>
VOTRE SESSION A EXPIRÉ !!!
<%end if %>
<%
else
Response.Write "Affichage impossible, une erreur ses produite."
end if
on error resume next
RS2.ActiveConnection = nothing
set RS2 = nothing
RS3.ActiveConnection = nothing
set RS3 = nothing
EndConnect
%>