Download the free trial version
Basic4android Video
Features
Tutorials and manuals
Showcase
Screenshots

Go Back   Android Development Forum - Basic4android > Basic4ppc (Windows Mobile) > Questions (Windows Mobile)
Documentation Wiki Register Members List B4P Search Today's Posts Mark Forums Read

Questions (Windows Mobile) Post any question regarding Basic4ppc.

Can run program through b4ppc on device, but not compiled

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 01-26-2009, 01:29 AM
Junior Member
 
Join Date: Jan 2008
Posts: 14
Exclamation Can run program through b4ppc on device, but not compiled


I am working on a program and can run it through b4ppc on the device, but not a compiled version......out of memory errors.
It will only compile non-optimized and not forced qvga.
I'm new to this.
Is it possible to get someone to look at/run my program and help figure out what needs to be done to compile it optimized for device.
It's still a work in progress, but it works without errors in b4ppc.
Definitely not in commodre64 basic anymore!
Reply With Quote
  #2 (permalink)  
Old 01-26-2009, 08:41 AM
agraham's Avatar
Basic4ppc Expert
 
Join Date: Jul 2007
Location: Cheshire, UK
Posts: 6,072
Awards Showcase
Innovator medal Beta Tester Forum Contributer 
Total Awards: 3
Default

Line 28 - You don't need a return in App_start, let it run off the end

Line 42 et.al - There isn't a Hide method for a Form. The IDE treats this as a do-nothing, the optimised compiler complains. Use Close, it doesn't actually close a Form, it hides it, except for the main form when it ends the app.

Line 66 et. al. - You can't jump out of a Sub with the optimised compiler. You should not need to use Goto anyway.

Line 111 et. al. - I don;t know if this is the cause of out of memory but you appear to be repeatedly calling AddEvent on the same controls each test. This should be done once only on initialisation.

Line 171 et. al. - Attempted Goto out of scope again!

Is that enough for now
Reply With Quote
  #3 (permalink)  
Old 01-27-2009, 12:24 AM
Junior Member
 
Join Date: Jan 2008
Posts: 14
Default

thanks for the quick response! I'll start make the changes and let you know how it goes. Hopefully I'll grasp this programming language better soon!
Reply With Quote
  #4 (permalink)  
Old 01-29-2009, 12:29 AM
Junior Member
 
Join Date: Jan 2008
Posts: 14
Angry Error compiling program.

Error compiling program.
Error message: CS1519:Invalid token '='in class, struct, or interface member declaration

Still not getting any further ahead..........all I seem to ham done is trippled my code and still get out of memory error on regular compile and the cs1519 on the other two compiles.
Reply With Quote
  #5 (permalink)  
Old 01-29-2009, 05:03 AM
Knows the basics
 
Join Date: Jan 2009
Location: Germany and Canarias
Posts: 58
Default

espresult.text=((Right/(test))*100)

should be

espresult.text=(Right/test)*100

The compiler is sometimes picky on unnecessary brackets.
Reply With Quote
  #6 (permalink)  
Old 01-29-2009, 05:08 AM
Newbie
 
Join Date: Jul 2007
Posts: 7
Awards Showcase
Beta Tester 
Total Awards: 1
Default Wrong pictures

In form7 you have 4 buttons with image ="esp_zh.bmp" - change to esp_zh.jpg
Reply With Quote
  #7 (permalink)  
Old 01-29-2009, 09:33 AM
klaus's Avatar
Basic4ppc Expert
 
Join Date: Oct 2007
Location: Fully, Switzerland
Posts: 4,463
Awards Showcase
Forum Contributer Beta Tester Competition Winner 
Total Awards: 3
Default

I have tried your code.

Changed in Form7 the bmp files to jpg.

I can compile, with B4PPC version 6.50, for the device and for the desktop in both compiling modes.
Even with the non necessary brackets in espresult.text=((Right/(test))*100)

I cannot compile for Smartphones, ImageButtons are not supported.

Are you shure that you compile exactly the same source code as the one you posted ? Because in that case you should have got the error with the bmp and jpg files.

Unfortunately I don't have an answer to your question, but at least you know that it should work.

Attached the 4 exe files.

What device do you have?

Best regards.
__________________
Klaus
Switzerland

Beginner's Guide / User's Guide
Reply With Quote
  #8 (permalink)  
Old 01-29-2009, 07:00 PM
Junior Member
 
Join Date: Jan 2008
Posts: 14
Default


Sorry, yes I forgot to change the form7 filenames to jpg's in the zip I attached. (had them right on the copy I was using on my computer though)

Tried my code on my computer at work, and it compiled fine..........so, I apparently have an issue with my home Basic4ppc/compiler/.net framework or something.

Thank-you all for the great help!!!!

I'm sure I will be back for help, on a new topic, once I try and figure out the hard stuff for my program like the table etc. But I will be of course returning to the tuturial/forum samples first.

Oh, and my device is an HP Ipaq 6945 pocket Pc.
Reply With Quote
  #9 (permalink)  
Old 01-30-2009, 01:24 AM
Junior Member
 
Join Date: Jan 2008
Posts: 14
Default

ok, I have figured out that the problem on my home computer, that was giving the compile errors that I was still getting after everyones fantastic help:

Reinstalling Basic4ppc was the only thing that fixed the optimized compile errors.

Thanks again, everyone!
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Can i use Basic4PPC to run a program whilst a device is in 'standby' Stead Questions (Windows Mobile) 3 08-03-2009 09:50 PM
running .cab files from a program on the device Louis Questions (Windows Mobile) 3 10-27-2008 08:00 PM
Compiled program won't run djmrozinski Questions (Windows Mobile) 12 02-27-2008 12:00 PM
DEVICE, Icon and program association. taximania Share Your Creations 2 01-05-2008 07:20 PM
Open serial port crashes program on device Steve Bug Reports 2 05-23-2007 09:52 PM


All times are GMT. The time now is 03:45 AM.


Powered by vBulletin® Version 3.6.12
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0