Wrox Programmer Forums
Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 2.0 > ASP.NET 2.0 Basics
|
ASP.NET 2.0 Basics If you are new to ASP or ASP.NET programming with version 2.0, this is the forum to begin asking questions. Please also see the Visual Web Developer 2005 forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 2.0 Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 1st, 2007, 11:10 PM
Registered User
 
Join Date: Apr 2007
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Update excel files in ip phone using VS.NET

Hi all, currently i am the 1st time doing on a project on ip telephony. By grabbing the web query using microsoft excel 2003 and using microsoft visual studio 2005 to read the code, how am i going to update the data in excel when i only have to initiate the ip telephony? Below is my code. Please do send me ur cmments regarding this problem. A thousand thanks~!
---------------------------------------------------------------------
Imports System.Net
Imports System.io
Imports System.Text
Imports System.Xml
Imports System.Data.OleDb
Imports System.Data

Partial Class leader
    Inherits System.Web.UI.Page

    Dim cid As String
    Dim myDataset As New DataSet

    Enum Datatype
        Name
    Team
        Goals
        ID
        Key
    End Enum

    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        eplinfo()
    End Sub

    Private Sub eplinfo()

        Dim strConn As New OleDbConnection(MyGlobal.semConnection)

        'Dim cid As String = Request.QueryString("cid").ToString
        'Dim ext As String = Request.QueryString("ext").ToString
        Dim title As String = "Scoring Leaders"

        'LogCSV.AddLog("leaders", cid, ext)

        Response.ContentType = "text/xml"
        Response.Expires = -1
        Response.Buffer = True

        Response.Write("<CiscoIPPhoneText>")
        Response.Write("<Title>" & title.ToString & "</Title>")
        Response.Write("<Prompt>" & MyGlobal.PROMPTMSG_IPPS & "</Prompt>")

        Dim myDataAdapter As New OleDbDataAdapter("SELECT * FROM [leader$] ", strConn)
        myDataAdapter.Fill(myDataset)

        Dim name_Row As String
        Dim team_Row As String
        Dim goal_Row As String = String.Empty
        'Dim myRow As DataRow

        Response.Write("<Text>")

        name_Row = String.Empty
        goal_Row = String.Empty
        team_Row = String.Empty
        Dim i
        For i = 1 To myDataset.Tables(0).Rows.Count - 1

            name_Row = myDataset.Tables(0).Rows(i).Item(Datatype.Name)

            team_Row = myDataset.Tables(0).Rows(i).Item(Datatype.Team)
            goal_Row = myDataset.Tables(0).Rows(i).Item(Datatype.Goals)

            Response.Write(name_Row & " " & "(" & team_Row & ")" & " " & "Goals Scored: " & goal_Row & Environment.NewLine)

        Next

        Response.Write("</Text>")

        Response.Write("<SoftKeyItem>")
        Response.Write("<Name>Back</Name>")
        Response.Write("<URL>" & MyGlobal.GetBaseURL(Request.Url.AbsoluteUri) & "eplmenu.aspx" & "</URL>")
        Response.Write("<Position>2</Position>")
        Response.Write("</SoftKeyItem>")


        Response.Write("<SoftKeyItem>")
        Response.Write("<Name>Home</Name>")
        Response.Write("<URL>SoftKey:Exit</URL>")
        Response.Write("<Position>4</Position>")
        Response.Write("</SoftKeyItem>")

        Response.Write("</CiscoIPPhoneText>")

    End Sub

End Class
---------------------------------------------------------------------
Any help given will be appreciated.

Thanks alot :)
 
Old April 1st, 2007, 11:33 PM
Registered User
 
Join Date: Apr 2007
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

oh yes and also, the web im grabbing is a .aspx address. Wish to have a real time update just by initiating only the ip telephony. Is it gonna do with microsoft visual studio 2005's coding? Please do send give ur professional advice to a new user like me. Thx alot~






Similar Threads
Thread Thread Starter Forum Replies Last Post
Phone Dialer using .net 2.0 priyan.viji Pro VB 6 1 August 9th, 2007 10:14 PM
Update query: Editing phone number fields? monacle Access 2 February 27th, 2007 08:55 AM
Excel sheet accessing(edit/update) in asp.net hemant.dna ASP.NET 1.0 and 1.1 Basics 0 January 31st, 2007 07:37 AM
ASP.NET 2.0 Printing Excel Files lagyossarian ASP.NET 2.0 Basics 0 April 10th, 2006 08:58 AM
Update Excel File Using ADO .Net briancronin123 ADO.NET 0 June 3rd, 2004 02:20 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.