|
MyCmd.CommandText = "SELECT SectionID FROM([Section]) WHERE (CourseID = '" & ComboBox96.Text & "')"
change to:
MyCmd.CommandText = "SELECT SectionID FROM [Section] WHERE CourseID = '" & ComboBox96.Text & "'"
|
|
|
|
|
thinks but it dos not work
the same error "Specified cast is not valid"
the query i use it in other place and it work
i don't think the error from the query
|
|
|
|
|
asha_s wrote: MyReader.GetString("0"))
Doesn't that take an Integer as varaible?
|
|
|
|
|
i use the same with the same statment with the same argument and it work
|
|
|
|
|
im doin my project which using file stream to keep the videos into DB
but when i want to show them on my website by using Media player
it juz can play only small size of video like 3MB
but my data will be more than 50MB which cannot be show up
so any idea?
|
|
|
|
|
There's got to be something else wrong because there is no limit to the file size that can be played.
For a file that large, I'd probably recommend serving up that content using MS Media Server instead of an HTTP file download.
|
|
|
|
|
Hi freeks
i have a little problem: so i have a array of value which looks like
0 0 0 0 0 0 2 3 9 8 1 4 5 0 0 0 0 0 0 0 5 4 6 4 8 4 3 0 0 0 0 0 0 5 4 3 2 2 1 0 0 0
what i want is to get the max value in every block of values between the nulls and his Index;
so that i get like this result : in this case just in hashtable(whithout to write "value" and "Index" like strings i mean)
value Index
9 --> 8
8 --> 24
5 --> 33
normally the values comes once in a block; this just an simple example.to know how it works.
thy a lot fiends
|
|
|
|
|
This isn't as complicated as you make it sound. All you have to do is put this array through a method that looks for blocks of numbers, bracketed by 0's. Then you run each block through another method that returns the highest number in that block. I simple scan of all the values, keeping track of the highest value you saw should do it.
|
|
|
|
|
thx first
could you wrtite me an example to see how it could be? i m a little noob (
thx brother
|
|
|
|
|
If I wrote it for you, you wouldn't learn anything.
But, here's a pseduo-code layout of how you can do it:
GetMaxValueInArray
currentMaxValue = 0
For element in the array
If element(i) > currentMaxValue
currentMaxValue = element(i)
End If
Next
Return the currentMaxValue
|
|
|
|
|
outaleb wrote: could you wrtite me an example to see how it could be?
No. He might be leaving it as an exercise for you...
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
|
|
|
|
|
ok i will try;
but i know how i get the max value of the hole arrray; my problem is that i want the max of each block of values and their belonging Index in this array in a hashtable for example.
but i ll give my best
thx all
|
|
|
|
|
Try the pseudocode Dave gave you. Let us know how it goes...
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
|
|
|
|
|
hi guys;
it s a little difficult than you thought;idont wanna get the Max value of all but Max-values between the blocks.
<br />
For zahl = 0 To Intens_Array.GetUpperBound(0)<br />
If Intens_Array(zahl) = 0 Then<br />
Max = 0<br />
Else<br />
If Max < Intens_Array(zahl) Then<br />
Max = Intens_Array(zahl)<br />
End If<br />
End If<br />
Next<br />
thats easy; but what i want is to get the Max value between each block of zero-values;
look i have an array with the values like
00000041932321459000000076384600000323453200000
my question is, how could i get the max VALUES whithin each block and his index in this arry for this example: 9-->index:17
8-->index:28
5-->index:40
i hope iwas clear;
so let me us pls )
thx all
|
|
|
|
|
Good day.
I'm running the following code:
Me.ClientsTableAdapter.Fill(Me.DataDataSet.Clients)
Me.TransactionsTableAdapter.Fill(Me.DataDataSet.Transactions)
Me.ContactDetailsTableAdapter.Fill(Me.DataDataSet.ContactDetails)
The first 2 lines complete perfectly and the 3rd one also completes if there's no data in the ContactDetails table. An error is given once one or more rows exist in the table.
The error given is:
"index was out of range. Must be non-negative and less than the size of the collection. Parameter name: index"
I've tried filling other tables first as well, but with no success.
|
|
|
|
|
In all cases, does the error only show up on the ContactDetails table?? All the others Fill properly no matter what you do?
|
|
|
|
|
I would expect that the contactdetailstableadapter is firing events that are causing other code to run and cause the problem.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
I've a component (vb6 dll) with one method. I've created one virtual
directory in my xp machine and registered the dll in it. I've
generated wsdl file using ms soap kit 3 in the same folder. Now when i
call the service from another vb program in the same machine / some
other machine i got the below error.
WSDLOperation: Instantiating the dispatch object for method
name> failed HRESULT=0x80040154: Class not registered.
When i search on the web, it may the dll registration problem. But i'm
sure i've registered. I can add the dll as a reference in another vb
program. I can create an object in another asp program.
I've checked both are working fine. Now the problem is through web
service is shows the error.
I've tried in so many ways. After registered i've restarted the iis
and restarted the machine .....
But I've not get any solution.
If any idea pls help me.
Thanks.
Rishihar S
WinCrs
|
|
|
|
|
You wrote a COM-based .DLL and registered it on the system. The problem is probably with the web service description. It would appear that the class is registered, but the WSDL is using the wrong name to create an instance of the class.
I haven't used VB6 in over 6 years now, and never with a Web Service, so my experience is very limited.
|
|
|
|
|
I have stored the xml string in a StringBuilder variable sb.I want to write the string in sb to a file XMLsetting.xml.
Please help
thanks in advance
|
|
|
|
|
Ok. You already have the XLM is a StringBuilder, so call it's ToString method to get the String version of it. Then it's a simple matter of normal File I/O to write that string to a file. Try this example[^].
|
|
|
|
|
Hi I am working on a system where I need to read the existing contents of various spreadsheets into tables in a sql database. Eg: a spreadsheet named "Branches" needs the contents of its columns stored into a table named "branches" in the sql database. Can anyone give me a hand with this? Thanks
|
|
|
|
|
use the link below,it will be very useful.
"http://www.dotnetspider.com/qa/Question50.aspx"
<div class="ForumMod">modified on Thursday, March 20, 2008 5:31 AM</div>
|
|
|
|
|
Thanks
|
|
|
|
|
Hi All
I Want Know My Program Is Runing. If My Prog Is Runing Do'n Run Again
tanks All
|
|
|
|