Consulting

Results 1 to 2 of 2

Thread: Run Java code for web page via VBA

  1. #1
    VBAX Newbie Gb.pandey's Avatar
    Joined
    Jun 2011
    Location
    New Delhi
    Posts
    5
    Location

    Run Java code for web page via VBA

    Hi Guys

    Need your expert solution for my query.

    I am in process of developing a macro to fill online application form from data provided on MS Excel.

    So far I am able to

    1. Login to web site
    2. Open application form
    3. Fill data (stuck with some issue)
    4. Submit form

    On step 3 while filling the data there is a condition on web page that if two text box (Longitude and Lattitude) having value, only then a button (Get Airport) is activated for further action. Code is given below:

    <td class=caption_display width = "4%"></td>
    <td class=caption_Mandatory1 width = "30%" >&nbsp;(b) &nbsp;Lattitude </td>
    <td class=caption_data colspan=3><input style="width=120;" type=textbox name=txtLatitude maxlength=7 onfocus="return countdatavalue(ofrm.txtLatitude.value);" onBlur="validation_lat();return countervalues(ofrm.txtLatitude.value);" value=>XXDYYZZ (D=N(North) X=Degree,Y=Min,Z=Sec)</td>

    </TR>
    <tr>
    <td class=caption_display width = "4%"></td>
    <td class=caption_Mandatory1 width = "30%" >&nbsp;(c) &nbsp;Longitude </td>
    <td class=caption_data colspan=3><input style="width=120;" type=textbox name=txtLongitude maxlength=8 onfocus="return countdatavalue(ofrm.txtLongitude.value);" onBlur="validation_long();return countervalues(ofrm.txtLongitude.value);" value=>XXXDYYZZ (D=E(East) X=Degree,Y=Min,Z=Sec)</td>


    </TR>
    <tr>
    <td class=caption_Mandatory1 width = "4%"><center>8.</center></td>
    <td class=caption_Mandatory1 width = "40%" >&nbsp;(a) &nbsp;Name of Nearest Airport</td>
    <td class=caption_data colspan=3>
    <input type=button name="GetAirport" value="GetAirport" disabled onclick="return NewPage();">
    <input style="width=250;" type=textbox name=txtNearest_Airport maxlength=50 readonly=true value=></td>
    </TR>
    <tr>
    <td class=caption_display width = "4%"></td>
    <td class=caption_Mandatory1 width = "30%" >&nbsp;(b) &nbsp;Distance</td>
    <td class=caption_data colspan=3><input style="TEXT-ALIGN: right; width=70;" type=textbox maxlength=5 name=txtDistance readonly=true value=>&nbsp;&nbsp;(in Kms.)</td>
    </TR>



    Kindly suggest.

  2. #2
    VBAX Guru mancubus's Avatar
    Joined
    Dec 2010
    Location
    "Where I lay my head is home" :D
    Posts
    2,644
    pls see my post to your previous thread on the same request.

    and pls do not duplicate the threads.
    PLS DO NOT PM; OPEN A THREAD INSTEAD!!!

    1) Posting Code
    [CODE]PasteYourCodeHere[/CODE]
    (or paste your code, select it, click # button)

    2) Uploading File(s)
    Go Advanced / Attachments - Manage Attachments / Add Files / Select Files / Select the file(s) (multiple files can be selected while holding Ctrl key) / Upload Files / Done
    Replace company specific / sensitive / confidential data. Include so many rows and sheets etc in the uploaded workbook to enable the helpers visualize the data and table structure. Helpers do not need the entire workbook.

    3) Testing the Codes
    always back up your files before testing the codes.

    4) Marking the Thread as Solved
    from Thread Tools (on the top right corner, above the first message)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •