Startseite › Foren › Deutsches LiveCode-Forum › Galerie möglich? › Antwort auf: Galerie möglich?
April 15, 2019 um 23:20 Uhr
#14132
Prbier das mal:
on mouseUp
if the environment = "mobile" then
put files(specialfolderpath("external-documents")) into DieBilder
## Nur JPEGs erlauben, wer weiß, was sich sonst noch so in dem Ordner tummelt! 8-)
filter DieBilder with "*.jpg"
## IT is leer zu diesem Zeitpunkt.
## put it into field test (funktioniert garnicht)
put DieBilder into field "test"
if DieBilder = EMPTY then
answer "Kein JPEG vorhanden!"
exit mouseup
end if
## Du hast doch zwei leere Images auf der Karte, oder?
set the filename of img 1 to (specialfolderpath("external-documents") & "/" & line 1 of DieBilder)
set the filename of img 2 to (specialfolderpath("external-documents") & "/" & line 2 of DieBilder)
else
answer files "Bitte ein Bild auswählen:" with type "Jpeg,PNG|jpg,png|"
put it into DieBilder
put it into field "test"
end if
end mouseUp