Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3368: Cannot modify header information - headers already sent by (output started at /includes/bbcode.php:472)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3370: Cannot modify header information - headers already sent by (output started at /includes/bbcode.php:472)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3371: Cannot modify header information - headers already sent by (output started at /includes/bbcode.php:472)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3372: Cannot modify header information - headers already sent by (output started at /includes/bbcode.php:472)
OrbWorks Community Forum • View topic - Entering text in a field with FsetText

Entering text in a field with FsetText

Postby Mikael on Wed Apr 23, 2003 10:10 am

Hi,
I'm really stuck, so I have a few questions. Hope someone can help.

I'm trying to create my own keyboard by using a form created in PilRC. The test version only has two keys, in order to keep it simple. The problem is that I can't get it to type more than 1 char in a field using FsetText-despite the fact that MAXCHARS is set to 6. After looking at the docs I tried using REPEATBUTTONS instead. The trouble is that they are not handled by Fevent and I can't fully grasp Fctl (REPEAT) and FHAND, so now my code is going nowhere. The original code is like this:


//first keyboard test
#define FORM 3000
#define FIELD 3001
#define BITMAP1 4000
#define BITMAP2 4001
#define BITMAPCOLOR1 5000
#define BITMAPCOLOR2 5001
#define BUTTON1 6000
#define BUTTON2 6001

library "PToolboxLib"

include "Fctl.h"

main(){
int value1 = 81;
int value2 = 87;
char charVal;

OpenRsrcDb("KeyboardTest.prc");

Sony(1,1);

Fctl(LOAD, 3000);
Fctl(DRAW, 3000);

while(1) {
switch(Fevent(1)) {

case 6000:
charVal =(char)value1;
FsetText(3001,charVal);
break;
case 6001:
charVal =(char)value2;
FsetText(3001,charVal);
break;
}
}
}

N.B. I'm not even sure if I should be using REPEATBUTTONS!?

Do I perhaps need more fields?

Is it necessary for me to define the objects in my applet as above as it seems to work fine without definitions(this question probably shows that I'm still not 100 % clear about the difference between Resource Forms and Dynamic Forms).

Also could someone please explain the following PilRc terms:

LOCALE (it seems to be a required field though I can find no explanation and only "enUS" as an example-which I assume means English US. If so, why do I need it?

USABLE -again I assume this makes a button 'usable', though why would someone have an unusable button?

LEFT/RIGHTANCHOR -no idea.

Also, is there anywhere where I can download more 'newbie-friendly' docs for Pilrc. I've searched without success.

All help greatly appreciated,

Thanks,

Mikael:)
Mikael
 
Posts: 156
Joined: Sun Apr 13, 2003 9:19 am
Location: Denmark

Postby jstadolnik on Wed Apr 23, 2003 11:56 am

FsetText will overwrite all the text in a field. Use the Fctl INSERT command (#309) to append text to a field.

Joe

The PToolboxLib guy.
http://www.geocities.com/retro_01775/PToolboxLib.htm
jstadolnik
 
Posts: 1741
Joined: Wed Dec 06, 2000 3:34 am
Location: USA


Return to PocketC for Palm OS KB

Who is online

Users browsing this forum: No registered users and 1 guest

cron