Fehlermeldung

Begonnen von YoloBolo am 29. Juli 2018 · 15 Antworten

#1

Hallo zusammen,

wollte Code als App umwandeln:

global sechserAnzahl, dreizigerAnzahl

on preOpenstack
   set the fullscreenmode of me to "Letterbox"
end preOpenstack

on openStack
   go to cd "Startseite"
   cleaneingabe
   wait 5 seconds
   go to cd "Home"
end openStack

on mouseup
   if "button" is in the target then
      put the SHORT name of the target into action 
      if "6erWürfel" = action then
         put empty into fld "6erWürfelAngabe"
         set the visible of fld "6erWürfelAngabe" to true
         set the visible of widget "6erHacken" to true
      else if "" = action then
         
      else if "Würfeln" = action then
         if the SHORT name of THIS cd = "6er" then
            sechser
         else if the SHORT name of THIS cd = "30er" then
            dreiziger
         end if
      end if
   end if
end mouseup

//Navigation
on naviwürfel
   put the hilitedItemName of widget "Navigation Bar" into naviaction
   if "Home" = naviaction then
      if the SHORT name of This cd = "Einstellungen" or the SHORT name of This cd = "Würfeln" then
         cleaneingabe
      end if
      go to cd "Home"
   else if "Würfeln" = naviaction then
      answer naviaction
   else if "Einstellungen" = naviaction then
      go to cd "Einstellungen"
   else if "Zurück" = naviaction then
      go back
   end if
end naviWürfel

on cdhome
   set the hilitedItemName of widget "Navigation Bar" to "Home"
end cdhome

on cdwürfeln
   set hilitedItemName of widget "Navigation Bar" to "Würfeln"
end cdwürfeln

on cdeinstellungen
   set hilitedItemName of widget "Navigation Bar" to "Einstellungen"
end cdeinstellungen

//Würfeln
on wechselzu6er
   put empty into sechserNummer
   put empty into sechserAnzahl
   put fld "6erWürfelAngabe" into sechserNummer
   repeat with i = 1 to 6
      if i = sechserNummer then
         put i into sechserAnzahl
      end if
   end repeat
   if sechserAnzahl >= 1 then
      cleanwürfel
      repeat with z = 1 to sechserAnzahl
         put "würfelx"&sechserAnzahl&"_"&z into btnname
         set the visible of btn btnname of cd "6er" to true
         go to cd "6er"
      end repeat
   else
      answer "Die Anzahl der Würfel muss zwischen 1 und 6 liegen"
   end if
end wechselzu6er

on wechselzu30er
   
end wechselzu30er
   
   
on sechser
   put empty into btnnummer[1]
   put empty into btnnummer[2]
   put empty into btnnummer[3]
   put empty into btnnummer[4]
   put empty into btnnummer[5]
   put empty into btnnummer[6]
   repeat with z = 1 to sechserAnzahl
      if z = sechserAnzahl then
         repeat with h = 1 to z 
            put "würfelx"&z&"_"&h into btnnummer[h]
         end repeat
         repeat with g = 1 to 6
            put "wuerfel"&g into grafikName
            if h = 1 then
               set the icon of btn btnnummer[1] to the id of img (grafikName) of cd "Zubehör"
            else if h = 2 then
               set the icon of btn btnnummer[1] to the id of img (grafikName) of cd "Zubehör"
               set the icon of btn btnnummer[2] to the id of img (grafikName) of cd "Zubehör"
            else if h = 3 then
               set the icon of btn btnnummer[1] to the id of img (grafikName) of cd "Zubehör"
               set the icon of btn btnnummer[2] to the id of img (grafikName) of cd "Zubehör"
               set the icon of btn btnnummer[3] to the id of img (grafikName) of cd "Zubehör"
            else if h = 4 then
               set the icon of btn btnnummer[1] to the id of img (grafikName) of cd "Zubehör"
               set the icon of btn btnnummer[2] to the id of img (grafikName) of cd "Zubehör"
               set the icon of btn btnnummer[3] to the id of img (grafikName) of cd "Zubehör"
               set the icon of btn btnnummer[4] to the id of img (grafikName) of cd "Zubehör"
            else if h = 5 then
               set the icon of btn btnnummer[1] to the id of img (grafikName) of cd "Zubehör"
               set the icon of btn btnnummer[2] to the id of img (grafikName) of cd "Zubehör"
               set the icon of btn btnnummer[3] to the id of img (grafikName) of cd "Zubehör"
               set the icon of btn btnnummer[4] to the id of img (grafikName) of cd "Zubehör"
               set the icon of btn btnnummer[5] to the id of img (grafikName) of cd "Zubehör"
            else if h = 6 then
               set the icon of btn btnnummer[1] to the id of img (grafikName) of cd "Zubehör"
               set the icon of btn btnnummer[2] to the id of img (grafikName) of cd "Zubehör"
               set the icon of btn btnnummer[3] to the id of img (grafikName) of cd "Zubehör"
               set the icon of btn btnnummer[4] to the id of img (grafikName) of cd "Zubehör"
               set the icon of btn btnnummer[5] to the id of img (grafikName) of cd "Zubehör"
               set the icon of btn btnnummer[6] to the id of img (grafikName) of cd "Zubehör"
            end if
            wait 0.3 seconds
         end repeat
      end if
   end repeat
   repeat with i = 1 to z
      put random(6) into zahl
      put "wuerfel"&zahl into grafikname
      put "würfelx"&z&"_"&i into btnnummer
      set the icon of btn btnnummer to the id of img (grafikname) of cd "Zubehör"
   end repeat
end sechser

on dreiziger
   
end dreiziger

on cleaneingabe
   //6er
   set the visible of fld "6erWürfelAngabe" of cd "Home" to false
   set the visible of widget "6erHacken" of cd "Home" to false
   put empty into fld "6erWürfelAngabe" of cd "Home"
   //30er
   set the visible of fld "30erWürfelAngabe" of cd "Home" to false
   set the visible of widget "30erHacken" of cd "Home" to false
   put empty into fld "30erWürfelAngabe" of cd "Home"
end cleaneingabe

on cleanwürfel
   //6er
   repeat with i = 1 to 6
      repeat with z = 1 to i
         put "würfelx"&i&"_"&z into btnname
         set the visible of btn btnname of cd "6er" to false
      end repeat
   end repeat
   //30er
end cleanwürfel 

bekam jedoch diese Fehlermeldung:
"there was an error while saving standalone application
could not compile service support class"

kann mir da jemand helfen?

LG Max

Moderator
#2

Hallo Max,

diese Fehlermeldung meckert nicht an Deinen Skripten herum, sondern das ist ein Fehler beim Kompilieren zu einer ANDROID App.

Bitte mal diese Fragen beantworten:
Welches Betriebsystem?
Welche Version von LC?
Welche JAVA-Version ist bei Dir installiert?

Gruß

Klaus

#3

Windows 7
LiveCide Community 9.0 (dp11)
JDK 1.8

#4

Sorry, meinte natürlich LiveCode

Moderator
#5

Welche Version von JAVA (NICHT das Java Development Kit JDK) ist bei Dir installiert?

Es gibt mittlerweile auch die finale Version von LC 9, die solltest Du unbedingt installieren!
DP = Developer Edition, die können immer noch Bugs enthalten!

Diese URL mal bookmarken, dann kannst Du immer nachsehen, ob es eine neue Version gibt:
https://downloads.livecode.com/livecode/

#6

8

#7

Gerade nochmal probiert:

"There was an error while saving the standalone application
could not generate package manifest"

Moderator
#8

Hm, JAVA 8 ist richtig, höhere Versionen werden nicht von LC unterstützt.

Ich habe mal etwas recherchiert, hast Du ein PNG Bild als App Icon angegeben?
Wenn ja, versuche es mal OHNE das PNG Icon.

#9

Funktioniert nicht,
habe aber das "ß" zu "ss" geändert was funktioniert, aber trotzdem Danke

Moderator
#10

Was? Wie? ß zu ss? Wo genau? Und nun funktionierts?

#11

Aso, bei "com.yourcompany.yourapp", sieht bei mir jetzt so aus :"com.yourcompany.wuerfelspass"

Moderator
#12

Und funktioniert es jetzt? Das war der wichtigste Teil meiner Fragen!

#13

Ja

Moderator
#14

OK, was lernen wir daraus?

Na gut, ich sags Dir:
In der englischprachigen Welt der crossplatform Softwareentwicklung sollten wir auf
deutsche sprachliche Eingenheiten wie Umlaute und Sonderzeichen wie ß verzichten! :-)

#15

Keine "ß" sondern "ss" bei der Identifier verwenden

Moderator
#16

Sachichdoch! :-D

Du möchtest antworten? Melde dich an oder registriere dich.