3 Replies - 335 Views - Last Post: 30 August 2013 - 06:59 PM Rate Topic: -----

#1 DarenR  Icon User is offline

  • D.I.C Lover

Reputation: 448
  • View blog
  • Posts: 3,103
  • Joined: 12-January 10

code works in production but not dev ----

Posted 30 August 2013 - 12:56 PM

 Dim dt As Data.DataTable
            Dim sb_Business_Product_Workflow As New System.Text.StringBuilder
            params = New ParamCollection
            params.AddParam("order_detail_ID", order_detail_id)
            xmlticket = NewTicket.create_ticket("pr_get_order_detail_vendor_by_id", params)
            retval = spTicketData.getDataTable(xmlticket)
            dt = retval(1)


error

Unable to cast object of type 'System.Int32' to type 'System.Data.DataTable'.



this points to dt = retval(1)


i have tried to
cint(order_detail_id)
order_detail_id.tostring()

putting it on asp.net page an run at server

grabbing it from our logic page

other things



also do you think it is because some nut job declared "order_detail_id" as "_order_detail_id" a string = "" in a sub() and now i cant over ride the thing or do you think it is something else.

PS this works fine in production just not in dev and I refuse to make large changes on the production site itself. I want to test my new code that I am placing in before it hits production.


thanks

This post has been edited by DarenR: 30 August 2013 - 01:32 PM


Is This A Good Question/Topic? 0
  • +

Replies To: code works in production but not dev ----

#2 Michael26  Icon User is offline

  • DIC-head, major DIC-head
  • member icon

Reputation: 355
  • View blog
  • Posts: 1,521
  • Joined: 08-April 09

Re: code works in production but not dev ----

Posted 30 August 2013 - 01:09 PM

What does retval returns? Does it returns Int? I think it should return dataTable.

This post has been edited by Michael26: 30 August 2013 - 01:10 PM

Was This Post Helpful? 0
  • +
  • -

#3 DarenR  Icon User is offline

  • D.I.C Lover

Reputation: 448
  • View blog
  • Posts: 3,103
  • Joined: 12-January 10

Re: code works in production but not dev ----

Posted 30 August 2013 - 01:31 PM

it returns the data table but the error will not allow the data table to be returned. My thoughts are that our analyst stuck code somewhere on the production server that fixes this issue I just cant find it in dev.
Was This Post Helpful? 0
  • +
  • -

#4 _HAWK_  Icon User is offline

  • Master(Of Foo)
  • member icon

Reputation: 1052
  • View blog
  • Posts: 4,077
  • Joined: 02-July 08

Re: code works in production but not dev ----

Posted 30 August 2013 - 06:59 PM

What is the spTicketData type? What does getDataTable return?
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1