Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
P

Paul Hayman

@Paul Hayman
About
Posts
12
Topics
4
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Javascript/ASP/SQL
    P Paul Hayman

    I can't believe it, when I re-wrote the page to clean it up I forgot to add the include files.... All working now. Thanks again, and I will defiabtely look at .net. Cheers, Overtired Idiot.

    JavaScript help javascript database com

  • Javascript/ASP/SQL
    P Paul Hayman

    Thanks so much for your response, I fully intend on moving into the correct decade with .net, but i'm very new to web development and it's a bit of a learning curve even with ASP & Javascript. I will get there... I have been through the code as you suggested and i'm still having problems, I simply need an asp recordset into a javascript array. Maybe i'm just too tired, but I just can't get it right. Message: Object expected Line: 14 Char: 1 Code: 0 URI: http://localhost/floorfurnishings/autocompleteactive1.asp Line 14:

    objRs_cmd.ActiveConnection = MM_floordb_STRING

    <%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <!--#include file="Connections/floordb.asp" -->
    <%

    Dim arrPDFs
    Dim javascriptArrayValues
    Dim objRs
    Dim objRs_cmd
    Dim objRs_numRows

    Set objRs_cmd = Server.CreateObject ("ADODB.Command")
    objRs_cmd.ActiveConnection = MM_floordb_STRING
    objRs_cmd.CommandText = "SELECT * FROM dbo.Companies"
    objRs_cmd.Prepared = true

    Set objRs = objRs_cmd.Execute
    objRs_numRows = 0

    Function GetPDFsArray()
    If NOT objRs.EOF OR NOT objRs.BOF Then
    GetPDFsArray = objRs.GetRows()
    Else
    GetPDFsArray = ""
    End If
    End Function
    'Get array
    arrPDFs = GetPDFsArray

    If isArray(arrPDFs) Then
    for i=0 to uBound(arrPDFs,2)
    javascriptArrayValues=javascriptArrayValues & """" & arrPDFs(0,i) & """" & ","
    next 'i
    javascriptArrayValues=Left(javascriptArrayValues,Len(javascriptArrayValues)-1)
    Else
    javascriptArrayValues = "Error: No results for array"
    End If

    %>

    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Untitled Document</title>

    <%Response.Write(mySQL)%>
    <input type="text" name="pdfDesc" id="pdfDesc" autocomplete="off" />
    <script>
    customarray = new Array(<%=javascriptArrayValues%>);
    actb(document.getElementById("pdfDesc"),customarray);
    </script>

    </head>

    <body>
    </body>
    </html>

    <%
    objRs.Close()
    Set objRs = Nothing
    %>

    Thanks again.

    JavaScript help javascript database com

  • Javascript/ASP/SQL
    P Paul Hayman

    Would really appreciate somebody taking a look at this: http://www.codeproject.com/Messages/3618419/Newbee-Javascript-ASP-SQL-Lookup-Issue-Please-Help.aspx Sorry if it's the wrong section, but i'm not sure if it's a problem with the ASP or Javascript.

    JavaScript help javascript database com

  • DTS to Import .SQL file
    P Paul Hayman

    Sorry, was just happy to have a solution didn't think of posting.... sqlcmd -U USERNAME -P PASSWORD -S SERVER -d DATABASE_NAME -i yourfile.sql Pop that into a bat file and execute from the DTS package as a win32 process, all I need to do now is return a true or false from the bat file and pass back to the DTS package to confirm failure or success. Probably sounds easier than it will be.... Paul.

    Database help database question

  • DTS to Import .SQL file
    P Paul Hayman

    Actually the solution was fairly easy, just a one liner sorted it using sqlcmd. Thanks for your response though it's great that people do actually try and help. Paul.

    Database help database question

  • DTS to Import .SQL file
    P Paul Hayman

    Hi Guys, I have created a program that exports data from our old system to a .sql file that drops/creates and inserts, which works fine, the only problem I have is automating. How do you execute a SQL file from a DTS package? Obviuosly the file changes on a daily basis, but the filename can remain the same. Please help and thanks in advance, Paul.

    Database help database question

  • VB Webcontrol If Field Exists on form
    P Paul Hayman

    Thanks very much works great now. Paul.

    Visual Basic help

  • VB Webcontrol If Field Exists on form
    P Paul Hayman

    Hi Thanks again, I think I understand, but please forgive my newbieness. I dont know how to reference this index, I've tried several ways, but I feel like i'm shooting in the dark.

    If WebBrowser2.Document.GetElementsByTagName("input").item(22) >= 1

    Gives the following error: I get an error value is not a member of 'System.Windows.Forms.HtmlElement' What I thought I could do which also fails is:

    If Exists WebBrowser2.Document.GetElementsByTagName("input").item(22) then ..... else ......

    Paul.

    Visual Basic help

  • VB Webcontrol If Field Exists on form
    P Paul Hayman

    Following error: System.ArgumentOutOfRangeException was unhandled Message="Value of '25' is not valid for 'index'. 'index' should be between 0 and 20. Parameter name: index" Thanks for your response... much appreciated. Paul.

    Visual Basic help

  • VB Webcontrol If Field Exists on form
    P Paul Hayman

    Hi all, I am very new to VB so please forgive my basic questions. I have a webcontrol on a form that I use to populate fields on a webpage. The web page has an add another line function that in turn adds more fields to the form. So basically I need to check if a field exists before setting the value.

    WebBrowser2.Document.GetElementsByTagName("input").Item(22).SetAttribute("Value", Value)

    Works, but as I stated I need to check if item(22) exists before setting it's value. Thanks in advance for your help it really is appreciated. Paul.

    Visual Basic help

  • VB Webcontrol
    P Paul Hayman

    Works a treat. Thanks VERY VERY much.

    Visual Basic help

  • VB Webcontrol
    P Paul Hayman

    Hi all, I am very very new to VB and I am trying to use the web control to populate a form on an external website. I am able to load the site in the control on a form and have added a text box and a command button. On pressing the command button I am trying to populate a form field on the website with the contents of the texbox. I have tried all sorts of combinations but none have the desired results. Any help really would be greatly appreciated. Thanks in advance.

    Visual Basic help
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups