aldweb

Fermer I. aldweb

Fermer II. Gratuitiels PC

Fermer III. Gratuitiels Palm

Fermer IV. Partagiciels Palm

Fermer V. iziBasic Palm

Fermer VI. Connaissance Palm

Fermer VII. Ordinateur Poche

Fermer VIII. miniPortail

Spécial !



Version mobile
de l'aldweb Site

m.aldweb.com


Ni Français, ni Anglais ?

Essayez donc l'un de ces drapeaux :
[de] [es] [it] [pt]
Recherche




Météo / Spam / www

Météo Lyon


aldweb contre le SPAM


Newsletter
Pour avoir des nouvelles de ce site, inscrivez-vous à notre Newsletter.
S'abonner
Se désabonner
298 Abonnés
Sites web de la famille

Webmaster - Infos
News Amis
Visites

   visiteurs

   visiteurs en ligne

Sondage
Comment trouve-tu le nouvel habillage de l'aldweb Site ?
 
Superbe !
Joli
Moyen
Moche...
Résultats
forum.gifForum - iziBasic - Sujet n°1269

Forum - Forum
iziBasic - iziBasic


Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 257

actif  Sujet n° 1269  Weblink Creation

le 12/10/2005 @ 06:36
par ktimaster

Anonyme



Aldweb, I have a simple question can I create a HTML Weblink in iziBasic to open up the default web browser to a specific page. If I cant, Would you know how to make one in Pascal.
Ecrire à ktimaster   Poster une réponse  Haut

[]   


Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Réponse n° 1
--------
le 12/10/2005 @ 13:41
par aldweb

Anonyme

visiteur
Hello Ktimaster,

I don't know!
Because I have never been in the need of such a feature so far, so I never took the time to know how to send a HTML weblink to a Palm web browser.

The point is to know how the browser is registered as managing the HTML URLs and where to search for this kind of information, how to pass it to Palm OS, etc... Again, sorry, I don't know. But I am eager to know! As soon as you will have figured the mechanism, please let me know

Cheers,
aldweb
Ecrire à aldweb   Poster une réponse  Haut

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Réponse n° 2
--------
le 12/10/2005 @ 16:38
par Ktimaster

Anonyme

visiteur
OK I found some stuff to help... Unfortunatly it is in C rather then Pascal. I will include the example and mabey Aldweb can Help Decript it and help make an example for everyone. (And mabey implement it into a future version of iziBasic)
------------------------------------------
#include <PalmOS.h>
#include <WebBrowser.h>

WebBrowserCommand(false, 0 0sysAppLaunchCmdGoToURL, "www.aldweb.com", NULL)
Ecrire à Ktimaster   Poster une réponse  Haut

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Réponse n° 3
--------
le 12/10/2005 @ 18:43
par aldweb

Anonyme

visiteur
Indeed, my own search found the same documentation made by Palm here:
http://www.palmos.com/dev/support/docs/creatingwebenabledapps.pdf

The WebBrowserCommand() function is not an API call but a fully written function in C:
#include <PalmOS.h>
#include <WebBrowser.h>
Err WebBrowserCommand(Boolean subLaunch, UInt16 launchFlags, UInt16 command,
Char *parameterP, UInt32 *resultP)
{
UInt16 cardNo;
LocalID dbID;
DmSearchStateType searchState;
Err error;

if (resultP) *resultP = errNone;
error = DmGetNextDatabaseByTypeCreator(true, &searchState,
sysFileTApplication, WebBrowserCreator, true, &cardNo, &dbID);
if (error == errNone)
{
if (subLaunch)
{
SysAppLaunch(cardNo, dbID, launchFlags, command, parameterP, &result);
if (resultP) *resultP = result;
}
else
{
Char *newParamP = NULL;
if (parameterP)
{
newParamP= MemPtrNew( StrLen(parameterP) +1 );
if (newParamP == NULL) error = memErrNotEnoughSpace;
else
{
StrCopy(newParamP, parameterP);
MemPtrSetOwner(newParamP, 0); // The OS now owns this memory
}
}
if (error == errNone)
{
SysUIAppSwitch( cardNo, dbID, command, newParamP);
}
}
}
return error;
} //WebBrowserCommand


Note: this works only with the Web Browser 2.0 application, on Palm OS 5 only (as written in the documentation, link provided above).

The same thing will be much easier to write in iziBasic!
_WebBrowserCommand:
'Check OS version
V$­­=GETOSVER$­­
IF V$­­<"5.0" GOTO _WebError
'Search for Web Browser
B$­­=FINDFIRST$­­("appl","NF3P")
IF B$­­="" GOTO _WebError
RUN B$­­,"www.aldweb.com"
_WebError:
PRINT "Web Browser not found"
RETURN

I have not tested this small piece of code, but it should work.

Don't you believe that this is a great example, not to say a fantastic one, which demonstrates the easyness of using iziBasic!

Cheers,
aldweb
Ecrire à aldweb   Poster une réponse  Haut

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Réponse n° 4
--------
le 12/10/2005 @ 23:58
par ktimaster

Anonyme

visiteur
diddnt work... I keep getting a stack overflow message when I run the compiled program... When you use the iziBasic 'RUN' command does it use the SysAppLaunch API. If it does this would explain the error I am getting.
Ecrire à ktimaster   Poster une réponse  Haut

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Réponse n° 5
--------
le 13/10/2005 @ 01:01
par Ktimaster

Anonyme

visiteur
Nevermind... It turns out blazer has some other issues. I found another way around it
Ecrire à Ktimaster   Poster une réponse  Haut

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Réponse n° 6
--------
le 13/10/2005 @ 12:43
par aldweb

Anonyme

visiteur
I tried it on my Tungsten C, and it did work very well with Web Browser as I said in my previous e-mail.
I don't have Blazer so I don't know how to deal with it, if it accepts an input parameter and what its CreatorID is. But if it does accept an input parameter like Web Browser does, there is no reason why it should not work.

How did you solve your issue at the end?

Cheers,
aldweb
Ecrire à aldweb   Poster une réponse  Haut

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Réponse n° 7
--------
le 13/10/2005 @ 17:24
par Ktimaster

Anonyme

visiteur
The thing is with My Tungsten E|2 it Comes Bundled with A web Browser Called 'WEB'. it is in fact Blazer. in which you would use 'BLZ5' as the creator ID instead. Other then that it seems to work fine.

On a side note, I have used iziBasic to actually send an e-mail, and it WORKED!!!!!!!!!!!!
Ecrire à Ktimaster   Poster une réponse  Haut

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Réponse n° 8
--------
le 15/10/2005 @ 15:56
par aldweb

Anonyme

visiteur
Hello Ktimaster,

OK, only changing the creator ID was enough. There are not so many web browsers on the Palm market, so scanning for all possible types, launching the browser with a URL should easily be achieved from my source code example made for Web Browser.

Is it with Versamail that you sent the e-mail?
Please, send me the source code or share it here ... I'm lazy and don't really feel like searching for how to do... but I would love to have it to send some newsletter e-mails right from my Tungsten C

Cheers

@+
aldweb
Ecrire à aldweb   Poster une réponse  Haut
actif sujet actif   clos sujet clos   Important! Important!   Nouveau Nouveau message   -   Rectifier Rectifier message   Clôturer Clôturer sujet   Remonter Remonter
[]
Catégories de discussion  Forum 



 
^ Haut ^