Lo que intento es enviar una serie de números a un campo de texto, la idea es que los numeros se vayan poniendo en continuidad con el que se envio antes al campo de texto, pero eso no sucede, cada vez que mando un nuevo numero me sustituye el anterior que envie.
What I try to send a series of numbers to a text field, the idea is that the numbers will be put in continuity with the one that was sent before to the field of text, but that does not happen, every time I send a new number me Replaces the previous one you send.
la sintaxis que uso es la siguiente:
BrowserSetElement "WebBrowser6" "ct100$ContentPlaceHolder1$TBCelular" "[Valor]"
Es importante destacar que necesito enviar los numeros uno a uno y no una cadena unica con todos ellos
It is important to note that I need to send the numbers one by one and not a single string with all of them
Probelmas con "BrowserSetElement"
Moderator: Neosoft Support
Re: Probelmas con "BrowserSetElement"
gusgusl:
Try ...
Try ...
Code: Select all
BrowserGetElement "WebBrowser6" "ct100$ContentPlaceHolder1$TBCelular" "[Valor]"
SetVar "[Valor]" "[Valor]{textToBeAddedGoesHere}"
BrowserSetElement "WebBrowser6" "ct100$ContentPlaceHolder1$TBCelular" "[Valor]"
Re: Probelmas con "BrowserSetElement"
Funciona perfectamente el ejemplo que me pasaste, pero el campo de texto no me detecta los números ingresados
te lo explico mejor, ese campo de ingreso es para introducir números de celulares, y el campo al ingresar el tercer numero detecta automáticamente la compania telefónica y muestra los diferentes valor monetarios a cargar
It works perfectly the example you passed me, but the text field does not detect the numbers entered
I can explain it better, that field of entry on the page is to enter numbers of cell phones, and the field when entering the third number automatically detects the telephone company and shows the different monetary value to load
si lo hago desde la pagina logicamente funciona perfectamente, pero si le envio los numeros desde neobook no detecta la compania telefonica
If I do from the page logically works perfectly, but if I send the numbers from neobook does not detect the telephone company
me parece que lo que necesito hacer de alguna manera es actualizar ese campo de texto desde neobook cada vez que le envio un numero
I find that what I need to do somehow is to update that text field from neobook every time I send a number
te lo explico mejor, ese campo de ingreso es para introducir números de celulares, y el campo al ingresar el tercer numero detecta automáticamente la compania telefónica y muestra los diferentes valor monetarios a cargar
It works perfectly the example you passed me, but the text field does not detect the numbers entered
I can explain it better, that field of entry on the page is to enter numbers of cell phones, and the field when entering the third number automatically detects the telephone company and shows the different monetary value to load
si lo hago desde la pagina logicamente funciona perfectamente, pero si le envio los numeros desde neobook no detecta la compania telefonica
If I do from the page logically works perfectly, but if I send the numbers from neobook does not detect the telephone company
me parece que lo que necesito hacer de alguna manera es actualizar ese campo de texto desde neobook cada vez que le envio un numero
I find that what I need to do somehow is to update that text field from neobook every time I send a number
Re: Probelmas con "BrowserSetElement"
gusgusl:
If I understand you correctly, the field (on the web page) in question has some kind of "on change" event code (in javascript) that "populates another field (telephone company) based on a 3 digit code in this first field".
Do you have the name of the javascript function that handles the "on change" event ? (it should be part of the html for the web page) ... you might be able to invoke this javascript function from the NeoBook side (perhaps using BrowserExecScript)
If I understand you correctly, the field (on the web page) in question has some kind of "on change" event code (in javascript) that "populates another field (telephone company) based on a 3 digit code in this first field".
Do you have the name of the javascript function that handles the "on change" event ? (it should be part of the html for the web page) ... you might be able to invoke this javascript function from the NeoBook side (perhaps using BrowserExecScript)
Re: Probelmas con "BrowserSetElement"
INTENTA ESTO, AQUI TIENES EL 'PUB' Y EL 'HTML' QUE USE (AUTOMATIZA TU SOLICITUD)
EL HTML, LLAMALO "cel.html"
EL 'PUB' LLAMALO "celular.pub"
ME CUENTAS DEL RESULTADO
GRACIAS POR LEERME
EL HTML, LLAMALO "cel.html"
Code: Select all
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>ENTRADA de TELEFONOS</title>
<script>
function accion(){
var Teles = document.getElementById("TBCelular").value;
var LsTel =Teles.split("\n");
var Last = LsTel.length-2;
var TelNum =LsTel[Last].split("-");
document.getElementById("CelComp").innerHTML="COMPAÑIA TELEFONICA=="+TelNum[1];
}
</script>
</head>
<body>
<div align="center">
<h2>HOLA DESDE COSTA RICA</h2>
<textarea cols="20" rows="10" name="TBCelular" id="TBCelular"></textarea><hr>
<p style="font-size:24px; color: blue; font-weight: bold;" id="CelComp"> COMPAÑIA TELEFONICA</p>
</div>
</body>
</html>
Code: Select all
NBW Publication Source File
(C)2016 NeoSoft Corp.
Title=Untitled NeoBook Publication
Language=US
NeoBookVer=5,80
ScreenColors=16777216
ScreenWidth=480
ScreenHeight=360
BkndColor=0
ScreenAutoSize=Yes
LinkColor=16711680
WindowStyle=0
WindowOrder=0
WindowPos=0
WindowProps=31
BiDiMode=0
UseUpdateTimer=Yes
ReturnTime=60
ShapeTransColor=536870912
SplashProps=3
CompressPub=Yes
CompiledName=H:\Extractor\Bak\cambie_cel.exe
CompileType=0
MediaType=0
FilesIncluded=1
FontsIncluded=2
FontsToCompile=|
CopyExternalFiles=No
SetupMedia=3
SetupInstDir=C:\MyProgram
SetupTitle=Setup
SetupColors=16711680|0|65535
VersionMajor=1
VersionMinor=0
VersionRelease=0
VersionBuild=0
ReqExLevel=1
CustomFontName=Arial
CustomFontSize=9
CustomFontStyle=0
CustomCharset=1
CacheSize=30
ExtractOp=132
L_OK=OK
L_CANCEL=Cancel
L_YES=Yes
L_NO=No
L_CLOSE=Close
L_ERRORTITLE=Error
L_FINDTITLE=Find
L_FINDPROMPT=Find &What
L_FINDFIRST=&Find First
L_FINDNEXT=Find &Next
L_FINDERROR=Search text not found.
L_PWORDTITLE=Password required
L_PWORDMSG=Before continuing, you must first|enter the correct password.
L_PWORDPROMPT=&Password:
L_PWORDERROR=That's not the right password!
L_MEDIAERROR=In order to play this type of file you must install|the appropriate multimedia hardware and/or|software.
L_INTERNETERROR=Unable to locate Internet Browser software.
L_ABORTFUNCTION=Do you want to cancel this function?
L_EXTRACTERROR=This file could not be extracted and cannot be played.
L_INSTDIRPROMPT=Please enter the drive and directory where you would like this program to be installed. To accept the default drive and directory, simply press Enter.
L_INSTFOLDERPROMPT=Do you wish to create a program folder?
L_INSTRUNPROMPT=Do you want to run
L_INSTDISKPROMPT=Please insert disk #
L_INSTDISKERROR=That's not the correct disk, try again.
L_INSTGENERROR=The installation has terminated.
L_INSTEXITPROMPT=Do you really want to cancel the installation?
L_INSTWINTITLE=Setup
L_INSTPROGTITLE=Extracting Files...
L_SENDEMAIL=Sending Mail...
L_MAILSERVER=Please enter the name of your outgoing email server:
L_COPY=Copy to Clipboard
L_SELECTALL=Select All
L_DONWLOADFILE=Downloading: %s
L_PLEASEWAIT=Please wait...
TrayMenuBegin
MenuName=TrayOpen
MenuText=Open
MenuState=3
MenuKey=0
MenuAction=SetVar "[WindowState]" "Normal"
MenuName=TrayExit
MenuText=Exit
MenuState=3
MenuKey=0
MenuAction=Exit "" ""
MenuEnd
MasterPage
NewPage=New Page
PageStyle=0
PageColor=16777215
PageGradient1=16711680
PageGradient2=255
PageGradientDir=1
WallpaperStyle=0
EffectSpeed=0
ObjectType=9
Name=EnCel
X=174
Y=4
W=132
H=31
Anchor=0
VarName=[nTBCel]
Align=1
EditMask=999 000-0000
EditLen=12
ObjAction=strparse "[nTBCel]" "-" "[cel]" "[x]"¶math "[cel2]" "" "[cel2]"¶strlen "[cel2]" "[l2]"¶ifex "[cel2]<>Error AND [l2]=4"¶ BrowserGetElement "Web" "TBCelular" "[Valor]"¶ SetVar "[Valor]" "[Valor][nTBCel][#13]"¶ BrowserSetElement "Web" "TBCelular" "[Valor]"¶ BrowserExecScript "Web" "accion()" "JScript"¶ setvar "[nTBCel]" ""¶ SendKeys "" "{Home}"¶endif
LineColor=0
LineWidth=1
LineStyle=0
FillColor=14213368
FillPattern=0
Font=Arial
FontSize=14
FontStyle=0
FontCharset=1
TextColor=0
TabOrder=2
ObjectType=14
Name=Web
X=0
Y=41
W=480
H=319
Anchor=0
FileName=cel.html
VarName=[WebStatus]
TitleVarName=[WebTitle]
URLVarName=[WebAddr]
LineColor=0
LineWidth=1
LineStyle=0
FillColor=12632256
FillPattern=0
Font=Arial
FontSize=10
FontStyle=0
FontCharset=1
TextColor=0
TabOrder=3
GRACIAS POR LEERME
COSTA RICA
PURA VIDA
PURA VIDA
Re: Probelmas con "BrowserSetElement"
Este el codigo de la pagina que aparece si hago una inspeccion del campo de texto:
This the code of the page that appears if I make an inspection of the text field:
<input name="ctl00$ContentPlaceHolder1$TBCelular" maxlength="9" id="ctl00_ContentPlaceHolder1_TBCelular" tabindex="2" autocomplete="off" onkeyup="setearLeyenda(event)" onkeypress="javascript:return ValidNum(event);" style="border-color:Gray;border-width:3px;border-style:solid;font-size:40px;font-weight:bold;height:42px;width:250px;" type="text">
This the code of the page that appears if I make an inspection of the text field:
<input name="ctl00$ContentPlaceHolder1$TBCelular" maxlength="9" id="ctl00_ContentPlaceHolder1_TBCelular" tabindex="2" autocomplete="off" onkeyup="setearLeyenda(event)" onkeypress="javascript:return ValidNum(event);" style="border-color:Gray;border-width:3px;border-style:solid;font-size:40px;font-weight:bold;height:42px;width:250px;" type="text">