Jump to content

.ie help changing a value in table


fbar
 Share

Recommended Posts

:alien:

here is the html code of the web page

<input onkeypress="EnterKeyLeaves(this.id,event);" onblur="LeaveTextBox(this.id, 'tblARecords_0_hlPointsto', 'tblARecords_0', 'arecord', 'data', 'tblARecords_0_pointstotd', 'Points to');" onfocus="CheckForSameRow('tblARecords_0');" onclick="ARecordNoEdit=true;" onchange="ARecordChange('tblARecords0hdnRecModified', 'tblARecords_0', 0, '0');" style="width: 400px; display: none;" id="tblARecords_0_txtPointsto" value="2.125.69.0" name="tblARecords_0_txtPointsto" type="text">

im  trying to change the value="2.125.69.0"

id = "tblARecords_0_txtPointsto"

how would i change the value ive tryed to submit it has a form but with no joy

please any help would be helpful

its a table input

thanks rob

:alien:

<code sample tag>

     If $oForm.action <> "0" And Not StringInStr($oForm.action, '.php') Then  ;submit
       _IEFormSubmit($oForm, 0)
       _IELoadWait($oIE)
         $gotourl1 = GUICtrlRead ( $URL1 )
        _IENavigate($oIE,$gotourl1)
Local $dnsinputform = _IEFormGetObjByName($oIE, "form1")
Local $dnsinputbox = _IEFormElementGetObjByName($dnsinputform, "tblARecords_0_hlPointsto")
_IEFormElementSetValue($dnsinputbox, $ip ,1)

MsgBox(1,"new ip just ip call",$ip,2)
$newvalue =_IEFormElementgetValue($dnsinputbox)
MsgBox(1,"new value set",$dnsinputbox,2)
        _IEQuit($oIE)
guictrlsetdata ($oldip,$ip)

</code tag>

now i set this up as if its a form but it not a form it a table and i need a little help please

<code from firefox under focus code tag>

<td id="tblARecords_0_pointstotd" class="datacell OneLinkNoTx" align="left">
<input id="tblARecords0hdnPreviousPointsto" value="2.125.69.0"

</code from fire fox>

i just need tho change the value

thanks rob

Edited by fbar
Link to comment
Share on other sites

Hey fbar,

Just so we can easily look over your code, might you use autoit code tags to put your code into? easily done like so [ autoit ] ;code goes here [ /autoit ] (remove the spaces).

Or you can use the blue A (code) in the toolbar. :)

Local Enum $test = 1000 ; just an example
Edited by MikahS

Snips & Scripts


My Snips: graphCPUTemp ~ getENVvars
My Scripts: Short-Order Encrypter - message and file encryption V1.6.1 ~ AuPad - Notepad written entirely in AutoIt V1.9.4

Feel free to use any of my code for your own use.                                                                                                                                                           Forum FAQ

 

Link to comment
Share on other sites

IS THERE AND WAY I CAN CONTROL CLICK AND CONTROL SEND TO THIS

I JUST NEED TO CHANGE THE VALUE

<a style="" id="tblARecords_0_hlPointsto" class="textLink" onfocus="ARecordEditFocusRow('tblARecords_0', true, 'ddlTTLId');" onclick="ARecordEditRow('tblARecords_0', true, 'ddlTTLId');" href="#" title="2.125.69.0">2.125.69.0</a>

MOUSEMOVE WORKS BUT ITS PESTY

I DONT MIND MIXING _IE $oIE  UP WITH global $OIE

what ever will work silent in the background will do for me

Ive tryed

controlsend($IOE,"","tblARecords_0_hlPointsto","left",1)

but dosent do anything

Edited by fbar
Link to comment
Share on other sites

I would have a look at using _IE*** functions. 

Have a look at 

_IEGetObjById()
_IEPropertySet()

:)

Edited by MikahS

Snips & Scripts


My Snips: graphCPUTemp ~ getENVvars
My Scripts: Short-Order Encrypter - message and file encryption V1.6.1 ~ AuPad - Notepad written entirely in AutoIt V1.9.4

Feel free to use any of my code for your own use.                                                                                                                                                           Forum FAQ

 

Link to comment
Share on other sites

so what you saying is this minght work

$sID = "tblARecords_0_hlPointst"
$thedata = _IEGetObjById($oIE, $sID )

to get data

and to set datas

$ip = _getip
$sID = "tblARecords_0_hlPointst"
$setthedata = _IEPropertySet($oIE,$sID,$ip)

i havent tested it i just wrote a reply looks to easy

do it look right to you my new friend





			
				


	Edited  by fbar
	
	

			
		
Link to comment
Share on other sites

FAILED CODE

      Next
      If $oForm.action <> "0" And Not StringInStr($oForm.action, '.php') Then  ;submit
       _IEFormSubmit($oForm, 0)
       _IELoadWait($oIE)
         $gotourl1 = GUICtrlRead ( $URL1 )
        _IENavigate($oIE,$gotourl1)
Local $dnsinputform = _IEFormGetObjByName($oIE, "tblARecords_0")
Local $dnsinputbox = _IEFormElementGetObjByName($dnsinputform, "tblARecords_0_hlPointsto")
_IEFormElementSetValue($dnsinputbox, $ip ,1)

MsgBox(1,"new ip just ip call",$ip,2)
$newvalue =_IEFormElementgetValue($dnsinputbox)
MsgBox(1,"new value set",$dnsinputbox,2)
        _IEQuit($oIE)
guictrlsetdata ($oldip,$ip)

I THOUGHT I ADD THIS

im just in the process of testing the new code

Edited by fbar
Link to comment
Share on other sites

i have just had this failed attempt

debug message boxes return 0

and nothing happends

   Next
      If $oForm.action <> "0" And Not StringInStr($oForm.action, '.php') Then  ;submit
       _IEFormSubmit($oForm, 0)
       _IELoadWait($oIE)
         $gotourl1 = GUICtrlRead ( $URL1 )
        _IENavigate($oIE,$gotourl1)
;; collect data
$sID = "tblARecords_0_hlPointst"
$thedata = _IEGetObjById($oIE, $sID )
MSGBOX(1,"THE DATA",$thedata,2)
;set data
$ip = _getip
$sID = "tblARecords_0_hlPointst"
$setthedata = _IEPropertySet($oIE,$sID,$ip)
MSGBOX(1,"SET THE DATA",$setthedata,2)
MSGBOX(1,"THE IP",$ip,2)
Edited by fbar
Link to comment
Share on other sites

could the code be  
[autoit]
$sID = "tblARecords_0_hlPointst"
$thedata = _IEGetObjById($oIE, $sID )
$setthedata = _IEPropertySet($oIE,$thedata,$ip)
[ /autoit ]

ill test now

my code tagg not working

Edited by fbar
Link to comment
Share on other sites

more failed code

[autoit]

      Next
      If $oForm.action <> "0" And Not StringInStr($oForm.action, '.php') Then  ;submit
       _IEFormSubmit($oForm, 0)
         $gotourl1 = GUICtrlRead ( $URL1 )
        _IENavigate($oIE,$gotourl1)
       _IELoadWait($oIE)
$sID = "tblARecords_0_hlPointst"
$thedata = _IEGetObjById($oIE, $sID )
$setthedata = _IEPropertySet($oIE,$thedata,$ip)
;; collect data
;$sID = "tblARecords_0_hlPointst"
;$thedata = _IEGetObjById($oIE, $sID )
;MSGBOX(1,"THE DATA",$thedata,2)
;set data
$ip = _getip()
;$sID = "tblARecords_0_hlPointst"
;$setthedata = _IEPropertySet($oIE,$sID,$ip)
MSGBOX(1,"SET THE DATA",$setthedata,2)
MSGBOX(1,"THE IP",$ip,2)
_IEQuit($oIE)
ExitLoop

[autoit]

please can some one help me

Link to comment
Share on other sites

  • Moderators

fbar

Stop bumping your own threads every few minutes - or you may find you cannot bump them at all. :naughty:

M23

Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Link to comment
Share on other sites

  • Moderators

fbar,

You do not reply to Moderators like that - we are here to keep the forum running smoothly and you are becoming an irritant. Let me explain a few things:

 

- 1. We do not appreciate you opening umpteen threads which are all closely related.

- 2. We appreciate even less the fact that you bump your threads every few minutes. You have been told about the "Edit" button - and you then had the temerity to report those post to the Mods asking for them to be removed.

- 3. You have been asked to put your code in code tags - yet you still fail to do so.

- 4. And then you respond as you have above to a Mod.

Well, enough is enough. You will be unable to post for 24 hrs. When you return you had best start behaving in a reasonable manner or you will be removed from the community. :naughty:

M23

P.S. And I forgot to mention the PMs you kept sending me earlier today - stop that too. :naughty:

P.P.S. And I see you have just reported me to myself for the post I made above! Think yourself lucky I am not going to change what I have already decided to do to you! :ohmy:

Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...