Register for your free account! | Forgot your password?

Go Back   elitepvpers > Coders Den > .NET Languages
You last visited: Today at 17:32

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[VB.NET] InvokeScript / click item in html tablet

Discussion on [VB.NET] InvokeScript / click item in html tablet within the .NET Languages forum part of the Coders Den category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Aug 2011
Posts: 159
Received Thanks: 57
Question [VB.NET] InvokeScript / click item in html tablet

Hi,

Now I'll give up trying myself and I'm gonna ask your help
So I have web browser in my project and I'm trying to run javascript from the wep page. The script it below:

Code:
function startProvinciarumFight(aType, userId, serverId,country)
{
arenaType = aType;
provinciarumDefenderId = userId;
provinciarumServer = serverId;
provinciarumCountry = country;
sendRequest('get', 'ajax.php', 'mod=arena&submod=doCombat&aType='+arenaType+'&opponentId='+userId+'&serverId='+serverId+'&country='+country, 'attack_player_'+serverId + userId, 'arena_spinner', 'arena_spinner-img', 'arena_spinner-content');
}
This script can be run also by clicking image in the Html tablet in the same page:
Code:
<tr>
                                        <td>
                                            <a target="_blank" href="Link">
                                                                                                    [string]                                                                                           </a>
                                        </td>
                                        <td>[integer]</td>
                                        <td>
                                            [integer]                                        </td>
                                        <td>
                                            <span onclick="startProvinciarumFight(2, 45151, 5, 'fi');">
                                                <img style="cursor:pointer" src="7726/img/fordern.gif">
                                            </span>
                                            <span id="attack_player_545151" style="height: 20px; width: 20px;"></span>
                                        </td>
                                    </tr>
There nothing has id so that causes problems for me...

I can get those objects (2,45151,5,fi) easily - thats not a problem. I have tried to do this way:
Code:
'teksti() is the correct object (2, 15151, 5, 'fi')'
Dim ObjArr(3) As Object
            ObjArr(0) = CObj(New String(teksti(0)))
            ObjArr(1) = CObj(New String(teksti(1)))
            ObjArr(2) = CObj(New String(teksti(2)))
            ObjArr(3) = CObj(New String(teksti(3)))
            WaitForPageLoad()
            Webbrowser.Document.InvokeScript("startProvinciarumFight", ObjArr)

'or simple this way:'
Webbrowser.Document.InvokeScript("startProvinciarumFight", _
                    New Object() {teksti(0), teksti(1), teksti(2), teksti(3)})
Do you have any idea what is wrong with that "invokeScript"? Or do you know how I could click html item in tha table that has no id?
BeginnerDO is offline  
Old 12/13/2013, 14:36   #2
 
elite*gold: 0
Join Date: Aug 2011
Posts: 159
Received Thanks: 57
anyone?
BeginnerDO is offline  
Old 12/13/2013, 15:26   #3
 
'Heaven.'s Avatar
 
elite*gold: 1
The Black Market: 331/0/0
Join Date: Jun 2012
Posts: 5,819
Received Thanks: 3,200
Code:
If (Not (WebBrowser1.Document Is Nothing)) Then
        Dim ObjArr(4) As Object
        ObjArr(0) = CObj(New String(teksti(0)))
        ObjArr(1) = CObj(New String(teksti(1)))
        ObjArr(3) = CObj(New String(teksti(2)))
        ObjArr(4) = CObj(New String(teksti(3)))
        WebBrowser.Document.InvokeScript("startProvinciarumFight", ObjArr)
    End If

'Heaven. is offline  
Thanks
1 User
Reply


Similar Threads Similar Threads
[Release] 1-Click-Jobchange Item's
11/07/2015 - Flyff PServer Guides & Releases - 61 Replies
Hallo Elitepvper's, heute release ich eine Methode, die nicht vielen bekannt ist, eine 1-Click-Jobchange zu machen. Was ist enthalten? Es sind nur die ersten 4 Job's enthalten, sprich; Acrobat, Mercenary, Magician & Assist auf Level 16! Wie läuft die Jobchange ab und wie funktioniert es? Wenn man Level 2 erreicht hat, bekommt man 4 Items in's Inventar gelegt. Man muss eines davon doppelklicken, um die jeweilige Klasse zu sein.
[S]Item Datenbank (HTML/PHP)
04/04/2013 - Coders Trading - 6 Replies
Guten Abend zusammen, ich suche jemanden, der mir eine Item Datenbank coden könnte. Falls Ihr nicht wisst was das ist, hier mal ein Link: World of Warcraft Database - WOWDB Ich benötige lediglich eine Grundlage, das Anpassen kann ich selber... Aber es sollte so sein, dass man sich einloggen kann ( Nur Admin ) und dort neue Items, Quests etc. hinzufügen kann, bzw. bearbeiten kann.
[HELP] Right click item
05/22/2010 - EO PServer Hosting - 1 Replies
last night i took out several items from my shopping mall using shopeditor. then i changed the price of the items using this code.. delete from cq_itemtype where id >= 724043 and id <= 724043; insert into cq_itemtype (id,name,emoney) values ('724043', '10SpecialExpBall', '100000') then something wrong happened.. i cannot right-click on that item after i created it..
S> GACHA ITEM PER CLICK SURE GET.
12/23/2009 - Grand Chase Philippines - 23 Replies
PM ME IN YM --DELETED by Bry-- 250 gcph load only.. if you dont really believe dont add me.
Alle grünen Item mit 1 Click verkaufen
08/21/2005 - World of Warcraft - 0 Replies
Hallo Freunde! Ich versichere euch, daß ich über 2 Stunden die Suchfunktion benutzt habe und ich war mir sogar sicher, daß ich mir das wo notiert habe aber ich suche folgenden Beitrag: Vor kurzem hat einer ein MACRO veröffentlicht wo man mit einem Click alle grünen, blauen, violetten (aber wer will das schon :D ) Items mit einen Click verkaufen kann. Bitte postet mir den Link hier, falls ihr wißt wo es ist, oder schreibt noch mal wie es geht. VIELEN DANK! Have Fun!



All times are GMT +1. The time now is 17:32.


Powered by vBulletin®
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2025 elitepvpers All Rights Reserved.