dbTalk Databases Forums  

commandtimeout on privat adapter

microsoft.public.sqlserver.clients microsoft.public.sqlserver.clients


Discuss commandtimeout on privat adapter in the microsoft.public.sqlserver.clients forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Bart
 
Posts: n/a

Default commandtimeout on privat adapter - 12-04-2007 , 12:03 PM






Hi,

The adapter in an dataset, via generted code in VS2005, is defined private.
How can I set the commantimeout in this case.
For example, this a snipped from generated code on a dataset:

Public Overloads Overridable Function Fill(ByVal dataTable As
dsDeltaV.INTERFACEDataTable) As Integer
Me.Adapter.SelectCommand = Me.CommandCollection(0)


'following line is added manualy, but ofcourse overwritten next time the
generation tool has run:
Me.Adapter.SelectCommand.CommandTimeout = CommandTimeOut


If (Me.ClearBeforeFill = true) Then
dataTable.Clear
End If
Dim returnValue As Integer = Me.Adapter.Fill(dataTable)
Return returnValue
End Function


Reply With Quote
  #2  
Old   
Wei Lu [MSFT]
 
Posts: n/a

Default RE: commandtimeout on privat adapter - 12-05-2007 , 01:15 AM






Hello Bart,

I would like to suggest you add a custom partial class into the project
which is in the same namespace and has same name of your adapter class.

In that partial class, you could add your custom method to refer the
SelectCommand and other protected variable.



Sincerely,

Wei Lu
Microsoft Online Community Support

==================================================

When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.

==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.


Reply With Quote
  #3  
Old   
Wei Lu [MSFT]
 
Posts: n/a

Default RE: commandtimeout on privat adapter - 12-07-2007 , 03:00 AM



Hi ,

How is everything going? Please feel free to let me know if you need any
assistance.

Sincerely,

Wei Lu
Microsoft Online Community Support

==================================================

When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.

==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.