FORUMS PROFESSIONNELS
WINDEV
,
WEBDEV
et
WINDEV Mobile
Accueil
|
Messages récents
|
Connexion
|
Déconnexion
|
Français
Accueil
→
WEBDEV 2024
→
How do I replicate this HTML code in WebDev?
How do I replicate this HTML code in WebDev?
Débuté par Steve Thompson, 04 nov. 2014 10:31 - 7 réponses
Connectez-vous…
Steve Thompson
#1
Posté le 04 novembre 2014 - 10:31
Hi,
How do I replicate this HTML code in WebDev? It's the oncliick / onfocus bit I'm struggling with.
<input type="text" value="Test1" onclick="this.select()" />
<input type="text" value="Test2" onfocus="this.select()" />
Thanks, Steve
Signaler
0
0
Steve Thompson
#2
Posté le 13 novembre 2014 - 12:46
Anyone???
Surely I can't be that difficult!
Signaler
0
0
Fabrice Harari
#3
Posté le 13 novembre 2014 - 17:51
Hi Steve
not a lot of html developers here... So if you were instead to tell us
what you want to achieve in English, you may have more answers
Best regards
--
Fabrice Harari
International WinDev, WebDev and WinDev mobile Consulting
NEW: WXReplication, your open source replication system is available on
my web site!!!
WXShowroom.com: Show your projects!
More information on
http://www.fabriceharari.com
On 11/13/2014 6:46 AM, Steve Thompson wrote:
Anyone???
Surely I can't be that difficult!
Signaler
0
0
Steve Thompson
#4
Posté le 14 novembre 2014 - 10:15
Ok, sorry Fabrice,
When I click in a text field I'd like the current contents of the text field to be highlighted automatically so that any text input overwrites the current content.
Regards, Steve
Signaler
0
0
Steve Thompson
#5
Posté le 27 novembre 2014 - 10:31
Still no one knows?
Signaler
0
0
Zach Allen
#6
Posté le 16 décembre 2014 - 21:20
Hi Steve,
Sorry for the late response,
Assuming you already have created the Edit control(textbox) with some prepopulated value.
I used a Page Level Javascript Browser Function, this function is simply:
FUNCTION
selectField
(
id
) {
var control
=
document.getElementById
(
id
)
;
control.select
(
)
;
}
In the WLanguage Click (onclick) put
selectField
(
MySelf
..
Alias
)
Myself..Alias passes the html id to the javascript function.
FYI, WebDev alreayd does this natively when tabbing between controls. Put this code in the onclick function if you want to add the functionality when the user selects a field using their mouse.
Signaler
0
0
Zach Allen
#7
Posté le 17 décembre 2014 - 14:06
This solution was implemented in WebDev 18. It should work in WebDev 19 and actually hopefully just putting
this.select
(
)
;
as javascript into the onclick code.
Signaler
0
0
Steve Thompson
#8
Posté le 17 décembre 2014 - 16:58
Thanks Zach,
The first suggestion worked - the second didn't seem to...
Regards, Steve
Signaler
0
0
→ Revenir à WEBDEV 2024
WINDEV 2024
WEBDEV 2024
WINDEV Mobile 2024
WINDEV (précédentes versions)
Français
English
Español
Portuguesa
Fermer cette fenêtre
Type de recherche
Uniquement les sujets
Tous les messages
Période de recherche
Date indifférente
Moins d'une heure
Moins de 24 heures
Moins d'une semaine
Moins d'un mois
Moins d'un an
Annuler
Aperçu de votre message
Ajouter une image
Importer une image depuis une URL
Envoyer une image depuis un fichier de votre disque
Déposez ici un fichier ou cliquez sur "Parcourir..."
ou
Annuler
0%
WLangage
SQL
XML, HTML
JAVA, Javascript
Texte