httputils

caillaud

Member
Licensed User
Longtime User
Hi
B4X:
Try
cdvprest =cdvprest & Regex.Split("\|",myarray(i))(5) & "]"
Catch
cdvprest =cdvprest & "]"
End Try
if there is nothing in the area:Regex.Split("\|",myarray(i))(5)
i.e:||
I get a bug
in this zone sometime there is something,sometime nothing
if there is something I get it
I have to use try catch
what do you think
sincerely
michel
 
Upvote 0

thedesolatesoul

Expert
Licensed User
Longtime User
It looks weird to me. But if it works then it works!

I would probably do:
B4X:
data = Regex.Split("\|",myarray(i))
if data(5) <> null then
 cdvprest =cdvprest & Regex.Split("\|",myarray(i))(5) & "]"
else
cdvprest =cdvprest & "]"
end if

I'm not sure if this works. So your solutions is fine.
 
Upvote 0

caillaud

Member
Licensed User
Longtime User
hi
1) I am going to modify the server for not having null in this zone.
2) my listview: ListView1 is multi using:
-displaying hotels (about 35 items)
-displaying arrival dates (30 days from now:30items)
- displaying departure dates(10 items)
etc ..
the big problem I found is that there are interferences between these multiusages:
-textsize and textcolor are set by the first usage (displaying hotel)
and it is impossible to modify them in the other usages
-a line checked in an using is again considered as checked (background and foreground colors) in next using
background and font properties cannot be modified when they are set
is there a solution other than the multipication of listviews
thanks in advance
sincerely
michel
 
Upvote 0

caillaud

Member
Licensed User
Longtime User
hi
I send you an attachment
If you dont mind you could run the application and have a look
You will that listview1 keep the initial fontsize and color set at the display of the hotels

I apologize the look is ugly
english language is not implemented yet
sincerely
michel
 

Attachments

  • ziphotelbynet.zip
    14.5 KB · Views: 207
Upvote 0

caillaud

Member
Licensed User
Longtime User
Hi
1)if you click an hotel at the end the list you will see that the next list of arrival dates is altered.
try castel novel march20-march21 (mars2 mars21)
2)in the display of rooms offered
the first lines, category of room, is red
the second line, the price, is blue
it is the contrary which is implemented in the sub recupdispo
any idea about this problem?
it looks like something as byval byref all the parameters do seem correctly return

is it possible for you to destroy all the attachements
is necessary I send you new attachement

thanks in advance
sincerely
michel
 
Upvote 0

caillaud

Member
Licensed User
Longtime User
hi
what is wrong:
B4X:
Sub signdec(lg As String) As String
If lg = "1" Then
signdec = ","
Else
signdec = "."
End If           
End Sub
or here
B4X:
Sub montpresnew( mt0 As String,  lg As String) As String
montpresnew = ""
Try
Dim y As String:y = "":Dim mystr As String:mystr = "":Dim mt As String:mt = ""
mt = mt0
If mt.Length <= 5 Then
montpresnew = mt.Substring2(0, mt.Length - 2) & signdec(lg) & mt.Substring2(mt.Length - 2)
Else If mt.Length > 5 AND mt.Length <= 8 Then
montpresnew = mt.Substring(0, mt.Length - 5) + signmille(lg)
y = mt.Substring(mt.Substring(0, mt.Length - 5).Length)
montpresnew = montpresnew & y.Substring2(0, y.Length - 2) + signdec(lg) + y.Substring(y.Length - 2)
'Else 
'taille supèrieure à 8
End If
Catch
montpresnew = "0000"
End Try          
End Sub

thanks in advance
sincerely
michel
 
Upvote 0
Top