Click here to Skip to main content
       

.NET Framework

 
You must Sign In to use this message board.
Search this forum  
    Spacing  Noise  Layout  Per page  Show 
AnswerRe: How to Save/Load Files like Pictures in/from Database PinmvpRichard MacCutchan6-Jul-12 21:12 
SuggestionRe: How to Save/Load Files like Pictures in/from Database PinmemberICEFLOWER27-Jul-12 23:20 
AnswerRe: How to Save/Load Files like Pictures in/from Database PinmemberZappaDog24-Jul-12 3:41 
Questiontype in a datagridview and find in a listbox PinmemberGOURANG.RASTOGI6-Jul-12 17:23 
AnswerRe: type in a datagridview and find in a listbox PinmvpSandeep Mewara8-Jul-12 4:19 
QuestionCommunication Webservices or TCP Networking using C++/CLI PinmemberGer Hayden6-Jul-12 12:27 
Questionstring assignment in vb.net (It's too slow Pinmemberdl4gbe6-Jul-12 6:16 
Hello Smile | :)
 
I have a class :
 
cls_Communication_base
 
which has a private variable
 
Private p_Descr as String = nothing
 
and a public property
 
public Overrides property [Descr]() as String
get
return me.p_Descr
end get
set (ByVal value As String)
me.p_Descr = value
end set
end property
 
I have some load method, which loads data
from a data table and assigns the value from
the datarow to the property
 
row is a datarow from a datatable with 47000 Records
 

public overrides sub fillDataRow(byval row as system.data.datarow,byval bolBuffer as boolean)
 
...
 
If (Not row.isNull(5)) Then
' this line is too slow, really!!!!!!!!!!
me.Descr = row(5).tostring()
End If
 
....
 
end sub
 
Like said. Everything is ok in terms of speed. Only the line assigning the row value to the string property is really slow.
 
OK. I am skipping a lot of lines here to make the example easy. But, Without this line assigning the value to the property (but creating 47000 instances of my class and doing everything like querying the database takes Zero Seconds). Just including this one line and the whole thing needs 72 seconds
 
So, I guess there is something wrong in my way assigning strings to a property
 
Is there a better way assigning values to a string property?
 
Many thanks for helping Smile | :)
AnswerRe: string assignment in vb.net (It's too slow PinmemberMember 90823656-Jul-12 10:18 
AnswerRe: string assignment in vb.net (It's too slow PinmvpDave Kreskowiak6-Jul-12 10:59 
AnswerRe: string assignment in vb.net (It's too slow PinmemberMatt T Heffron10-Jul-12 14:42 
QuestionEntity Framework - Updates with eSQL PinmemberMember 82251805-Jul-12 9:08 
AnswerRe: Entity Framework - Updates with eSQL PinmemberNaerling12-Jul-12 6:00 
GeneralRe: Entity Framework - Updates with eSQL PinmemberMember 822518013-Jul-12 2:26 
GeneralRe: Entity Framework - Updates with eSQL PinmemberNaerling13-Jul-12 7:27 
QuestionHow to Install Created Windows Service via VB.Net PinmemberICEFLOWER22-Jul-12 13:24 
GeneralRe: How to Install Created Windows Service via VB.Net PinmvpAbhinav S2-Jul-12 16:22 
QuestionRe: How to Install Created Windows Service via VB.Net [modified] PinmemberICEFLOWER23-Jul-12 18:45 
SuggestionRe: How to Install Created Windows Service via VB.Net PinmvpRichard MacCutchan3-Jul-12 22:12 
GeneralRe: How to Install Created Windows Service via VB.Net PinmemberICEFLOWER24-Jul-12 2:31 
SuggestionRe: How to Install Created Windows Service via VB.Net PinmemberICEFLOWER27-Jul-12 23:21 
AnswerRe: How to Install Created Windows Service via VB.Net PinprotectorPete O'Hanlon3-Jul-12 22:30 
AnswerRe: How to Install Created Windows Service via VB.Net PinmemberMember 451899227-Aug-12 0:36 
GeneralHow to Change Registry Key Access Control/Rule PinmemberICEFLOWER22-Jul-12 0:06 
GeneralRe: How to Change Registry Key Access Control/Rule PinmvpDave Kreskowiak2-Jul-12 3:56 
AnswerRe: How to Change Registry Key Access Control/Rule PinmemberICEFLOWER22-Jul-12 4:38 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.


Advertise | Privacy | Mobile
Web01 | 2.6.130617.1 | Last Updated 19 Jun 2013
Copyright © CodeProject, 1999-2013
All Rights Reserved. Terms of Use
Layout: fixed | fluid