The ANSWER command in Windows 10 doesn't work

Deploying to Windows? Utilizing VB Script execution? This is the place to ask Windows-specific questions.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
trags3
Posts: 418
Joined: Wed Apr 09, 2014 1:58 am
Location: Las Vegas, NV

The ANSWER command in Windows 10 doesn't work

Post by trags3 » Mon Aug 06, 2018 12:46 am

I have built my stack on a MacBook Air High Sierra 10.13.6 using LC 9.0.1 (rc-1)
When I save as Standalone Application for Windows everything works without errors
I put the App on my Windows 10 Home build 1803 OS Build 17134.165 desktop and run it.
Everything works until I get to an "Answer" command.
I put an Answer command on a Label field on my Main Menu ie

on mouseUp
answer "Answer Works"
end mouseUp

When I click on the label the computer freezes and I can only quit the program with the Task

Everything else in the program seems to work but I have put several Answer commands in the app and the same thing happens when the program gets to any of them.

Is this a Bug?

I can get around it by displaying a box with the choices and buttons etc. but Answer is so convenient.

Thanks Tom

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9802
Joined: Sat Apr 08, 2006 7:05 am
Location: Los Angeles
Contact:

Re: The ANSWER command in Windows 10 doesn't work

Post by FourthWorld » Mon Aug 06, 2018 3:28 am

Double check in the Standalone Settings to make sure those windows are included in the build.
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

bogs
Posts: 5435
Joined: Sat Feb 25, 2017 10:45 pm

Re: The ANSWER command in Windows 10 doesn't work

Post by bogs » Mon Aug 06, 2018 5:28 am

Seems to work here, testing strictly just the answer dialog.

Code: Select all

on mouseUp
	answer "You rang?"
end mouseUp
Selection_003.png
Answer dialog Windows 10...
Of course, I didn't code it on a mac first, unfortunately I don't have access to one that will run Lc > 8.x.

If you really want to make sure bug/not bug though, you could do a simple stack with nothing in it except the answer dialog, like above, as well as what Richard said (I just used the default build alone search for inclusions setting myself).
Image

SparkOut
Posts: 2839
Joined: Sun Sep 23, 2007 4:58 pm

Re: The ANSWER command in Windows 10 doesn't work

Post by SparkOut » Mon Aug 06, 2018 6:38 am

It seems like this could be missing inclusions in the standalone settings. It works for me on Windows in every version of LC I have ever used. A bug this basic could not escape notice if it was Windows specific.
If compiling on a Mac and the standalone built for Mac works, but compiling on a Mac for a Windows executable that doesn't, then that would be worth treating more as a bug.

bogs
Posts: 5435
Joined: Sat Feb 25, 2017 10:45 pm

Re: The ANSWER command in Windows 10 doesn't work

Post by bogs » Mon Aug 06, 2018 12:43 pm

SparkOut wrote:
Mon Aug 06, 2018 6:38 am
If compiling on a Mac and the standalone built for Mac works, but compiling on a Mac for a Windows executable that doesn't
Yes, I think that if there is a problem, that is where it would be since I can build the same simple demo on Linux or Win and don't see the issue, but I'm not sure how it could happen considering how Lc builds a standalone (at least my understanding of it).

I seem to remember a similar issue cropping up not long ago that involved Windows. Hmmm.

*Edit - oh yah, "Answer file" crashes in windows xp. That one was also wierd.
Image

trags3
Posts: 418
Joined: Wed Apr 09, 2014 1:58 am
Location: Las Vegas, NV

Re: The ANSWER command in Windows 10 doesn't work

Post by trags3 » Mon Aug 06, 2018 2:38 pm

Hi SparkOut and bogs,
I tried a stack with 1 card 1 label and the code for the label:

on mouseUp
Answer "Answer works!"
end mouseUp

I made sure the inclusions (which I hadn't done before) for answer were checked.
Built the Standalone on my Mac and

Wallah!

The executable works on my windows computer!

However....

I went back to the app I am trying to get to work, made sure the proper inclusions were checked (they weren't before) built the standAlone on the Mac installed on my Windows and the problem still exists.

I then built the same stack on the Mac for Mac and it all works like a dream.

I probably will try to build it on my windows computer and see if that works but probably won't get to that until later today. I don't have LC on my windows machine.

Thanks for the input.

Tom

bogs
Posts: 5435
Joined: Sat Feb 25, 2017 10:45 pm

Re: The ANSWER command in Windows 10 doesn't work

Post by bogs » Mon Aug 06, 2018 3:13 pm

trags3 wrote:
Mon Aug 06, 2018 2:38 pm
I made sure the inclusions (which I hadn't done before) for answer were checked.
Built the Standalone on my Mac and Wallah! The executable works on my windows computer!
Congrats on that Tom :D
Curious (if you get the time to do another loop on the hamster wheel) using the same little stack, set the standalone settings to the default where it searches for inclusions, recompile it and test it again on Win10.

About the problem your having, I couldn't tell you what specifically to test to resolve it, but if we know it works with just the answer function, the rest *should* just be something specific to your application that doesn't work with it. Of course, what that something is I couldn't begin to guess :?
Image

trags3
Posts: 418
Joined: Wed Apr 09, 2014 1:58 am
Location: Las Vegas, NV

Re: The ANSWER command in Windows 10 doesn't work

Post by trags3 » Mon Aug 06, 2018 4:04 pm

Hi bogs,

I have compiled both files small and large both ways using the search for inclusions and set inclusions.
No difference. The small always works and the larger file doesn't.
The only thing that I have in the larger file other than normal text entry fields etc are 2 data grids.
However on my main menu there is nothing to do with a datagrid but there is a label that invokes the Answer command.
The app freezes on the Windows computer even if I don't go to any other card in the stack simply by clicking on the label field that invokes the answer command.
Everything in the app works including the datagrids. It is only when I get to an answer command that the app freezes.

I will do the workaround of displaying a box with 2 choices instead of using the "answer" command for now. There are only 3 answer commands in the app.

I'll keep you informed if I discover anything else useful. When I get time I will remove the datagrids and see if that makes a difference.

I appreciate the help, it's just that I now feel like there might be somekind of bug here.

Tom

bogs
Posts: 5435
Joined: Sat Feb 25, 2017 10:45 pm

Re: The ANSWER command in Windows 10 doesn't work

Post by bogs » Mon Aug 06, 2018 11:34 pm

The feeling is understandable, and certainly possible as it was in the other link I posted about XP. My general process is to eliminate the simplest part of the equation, obviously if the simple form with answer works, then the answer function is working on the compile. Why it wouldn't work with your app is a bit of a mystery requiring
  1. a brighter mind than mine and
  2. possibly someone that can test with a mac that can run 9.x :wink:
But I certainly hope you figure it out.
Image

trags3
Posts: 418
Joined: Wed Apr 09, 2014 1:58 am
Location: Las Vegas, NV

Re: The ANSWER command in Windows 10 doesn't work

Post by trags3 » Mon Feb 11, 2019 1:10 am

Hi,
I never really figured out the problem.
Rather than spend time trying to get the answer dialog to work with Windows I just created a card with the Answer dialog I needed. That works fine.

bogs
Posts: 5435
Joined: Sat Feb 25, 2017 10:45 pm

Re: The ANSWER command in Windows 10 doesn't work

Post by bogs » Mon Feb 11, 2019 12:13 pm

Well, that is one way to do it, congratulations :D

Having re-read the thread, though, I'm still not sure why just using the regular answer didn't work.
Image

Post Reply

Return to “Windows”