1,857 Posted Topics

Member Avatar for chdboy

The first thing I see, declaring i in the do/while loop resets the value of i, each time the loop iterates. Also Console doesn't normally work in a form. When you say navigate you'll have to be more specific. Your code doesn't really do anything. Do you want to be …

Member Avatar for chdboy
0
250
Member Avatar for anisha.silva

You start a timer routine, that will fire the class event every 10 seconds, your code can interrupt this if needed, by turning the timer off then on. Your class may need a method to allow this, perhaps `PerformEvent()`. Then this routine can call it with something like this, `MyClass.PerformEvent();` …

Member Avatar for tinstaafl
0
259
Member Avatar for AlphaXero

Reading the text file is actually fairly simple if you use the File class. Something like this works: I assumed the last part should have a '-' instead of a space 4 - 2 ^ 3 Imports System.IO Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click …

Member Avatar for tinstaafl
0
386
Member Avatar for robert.montgomery.75054

I'm pretty sure that won't work you might need to change it to this: Dim insSub As Integer = 0 Do Until intSub = strGrades.Length If strGrades(intSub) = strSearchFor Then intCount += 1 End If intSub += 1 Loop

Member Avatar for tinstaafl
0
163
Member Avatar for disjes
Member Avatar for ravenous
0
152
Member Avatar for ankit.4aug
Member Avatar for tinstaafl
0
501
Member Avatar for kumar_g
Member Avatar for chocolatte.lavista

If I understand what you're trying to do, there are several things that need changing in your code. Try this: #include <iostream> using namespace std; double box_area(int l, int w); double box_vol(int d, int l, int w); int main() { int l,w,d; double a,v; cout<<"length : "; cin>>l; cout << …

Member Avatar for asifalizaman
0
356
Member Avatar for Counterpartz

Here's an [example](http://www.daniweb.com/software-development/csharp/code/217212/bubbe-sort-and-selection-sort-in-c) for you.

Member Avatar for tinstaafl
0
242
Member Avatar for jovstudios

From your examples I assume if the new item equals the last item in the list then add the value to the last item, otherwise add the new item to the list. Something like this might work: Dim Itm As MSComctlLib.ListItem Dim Dbl1 As Double Dim Dbl2 As Double Set …

Member Avatar for AndreRet
0
163
Member Avatar for taekiewzz

Redirecting the standard error output, and maybe enabling the `CreateNoWindow` property, both available through the [ProcessStartInfo Class](http://msdn.microsoft.com/en-us/library/vstudio/system.diagnostics.processstartinfo%28v=vs.100%29.aspx), should solve your problem.

Member Avatar for taekiewzz
0
222
Member Avatar for Papa_Don

> "NullReferenceException was Unhandled" Try this `Dim strLine As String = ""`. It's usally a good habit to initialize every variable when you declare it. > send the number of "intIndex" to the Imediate box Debug.WriteLine(intIndex). Also you could set up a breakpoint, when your code stops, show the locals …

Member Avatar for TnTinMN
0
618
Member Avatar for sonyj
Member Avatar for HctiMitcH
0
230
Member Avatar for shaun.b

Word is probably using it's default behaviour, when you try to close a document without saving it. Try this, `wordDoc.Close(WdSaveOptions.wdDoNotSaveChanges);`.

Member Avatar for shaun.b
0
1K
Member Avatar for Ann95
Member Avatar for TnTinMN
0
638
Member Avatar for tsdeveloper

Pictures of the form don't mean much without the code that produced it. If you're unsure on how to add your code, in the edit window click 'Code', then paste your code in there, and click `Insert Code Snippet`

Member Avatar for terrier_unknown
0
132
Member Avatar for jovstudios

Something like this should work: Dim Itm As MSComctlLib.ListItem Dim X As Double Dim Dbl1 As Double Dim Dbl2 As Double Set Itm = ListView1.FindItem(txtCode.Text,0) If Itm Is Nothing Then Set Itm = ListView1.ListItems.Add(, , txtCode.Text) Itm.SubItems(1) = txtproductname.Text Itm.SubItems(2) = txtqty.Text Itm.SubItems(3) = txtprice.Text Itm.SubItems(4) = lbltotal.Text Else 'Qty …

Member Avatar for jovstudios
0
158
Member Avatar for sonyj

make the module public and declare any sub, function or variable as public, and they will be accessible to the whole project.

Member Avatar for Lethugs
0
323
Member Avatar for danielgr

Something like this might work: Public Class Call10Input Private _User As String = "" Private _Password As String = "" Public Property User() As String Get Return _User End Get Set(ByVal Value) _User = Value End Set Public Property Password() As String Get Return _Password End Get Set(ByVal Value) _Password …

Member Avatar for danielgr
0
184
Member Avatar for bornwith

Something like this might work: Private Sub BtnTest_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnTest.Click Dim IPmsg As String Dim NetshArgs As String IPmsg = Microsoft.VisualBasic.InputBox("Enter IP information", "Enter IP subnet and gateway with a sigle space between each.", "", 500, 700) Dim NewProcess As New ProcessStartInfo 'Change …

Member Avatar for bornwith
0
3K
Member Avatar for Papa_Don

You might want to consider using one multi-line textbox. One item on each line. Your code would then be greatly simplified Imports Syatem.IO 'to fill the textbox TextBox1.Lines = File.ReadAllLines("C:\Test2.txt") 'to save the data in the textbox, if you use the same filename it will get overwritten. File.WriteAllLines("C:\Test2.txt", TextBox1.Lines) If …

Member Avatar for TnTinMN
0
618
Member Avatar for maytham
Member Avatar for jeansantos

A couple of things. First port is an integer it should be initialized to 0 not "". Second both server and port must have actual valuesfor it to work right. host Type: System.String A String that contains the name or IP address of the host used for SMTP transactions. port …

Member Avatar for tinstaafl
0
321
Member Avatar for thewilf

I'm pretty sure that the headphone jack is hardwired to disconnect the speaker jack when a cable is plugged in, all of the ones I've seen are set up that way. You might need a speaker switch.

Member Avatar for thewilf
0
244
Member Avatar for <M/>

`ReadLine` is for reading input not writing to the output. You need `WriteLine` for that, `Console.WriteLine(answer[i]);`

Member Avatar for tinstaafl
0
224
Member Avatar for ralph.d.abernathy.1

This might work for you: float random_integer; float lowest=-100.00, highest=100.00; float range=(highest-lowest)+1; float sum = 0; float average; float minimum = highest, maximum=lowest; for(float index=0; index<100; index++) { random_integer = lowest+float(range*rand()/(RAND_MAX + 1.0)); if (random_integer > maximum) maximum=random_integer; if (random_integer < minimum) minimum = random_integer; sum += random_integer; cout << …

Member Avatar for tinstaafl
0
3K
Member Avatar for Sevyt
Member Avatar for tinstaafl
0
142
Member Avatar for monching

use a boolean variable. In the handler code, have 2 sets of code, run a set based on the condition of the boolean.

Member Avatar for tinstaafl
0
2K
Member Avatar for chocolatte.lavista

One fairly easy to understand, online, reference, is [cplusplus.com](http://www.cplusplus.com/reference/). It includes a pretty good search engine that will search the forum and the reference.

Member Avatar for tinstaafl
0
282
Member Avatar for EliteNMC

You could use a third array as a temproary holding space. temparray = array1 array1 = array2 array2 = temparray this will swap the arrays. To swap the other way change around array1 and array2

Member Avatar for tinstaafl
0
197
Member Avatar for harshi414

I think a lot will depend on the interface to the robot, and how that interface connects to you computer.

Member Avatar for Ancient Dragon
0
272
Member Avatar for aderogba08
Member Avatar for tin.marcelino

It would help to know which line was referenced in the error. If I'm not mistaken, generally that error is from not initializing an object when it is declared, then trying to give it a value. In your code `SQL1`, `Dset`, `searchacquisition`, `OleA` might fall in that category. `SQL1` is …

Member Avatar for ShahanDev
0
196
Member Avatar for peymankop

Your description is kind of vague. Perhaps uploading the code you're using will make it clearer.

Member Avatar for ChrisHunter
0
237
Member Avatar for karlcunanan

Probably the easiest is to, use a text file. Have each row on one line of a file with the values, converted to string, comma delimited. Use a `.csv` extension and the receiver should be able to load it into a spreadsheet. For readability maybe make the first line with …

Member Avatar for tinstaafl
0
485
Member Avatar for archangel1177

Copy the code you're using to the clipboard. Then click `Code` on the post menu. In the overlay paste your code. Correct any tab issues to make it more readable. Click `Insert Code Snippet` Now your code is formatted in the message field, and you can add any comments that …

Member Avatar for archangel1177
0
182
Member Avatar for ScarWars9

Here's a pretty good [starting point](http://msdn.microsoft.com/en-us/library/bb387100%28v=VS.100%29.aspx) Here's more [good info](http://msdn.microsoft.com/en-us/library/vstudio/gg145036%28v=vs.100%29.aspx) Of course a search of the posts here should turn up plenty of posts about XML

Member Avatar for tinstaafl
0
300
Member Avatar for waqas.zafar.125

> thanx bro but i have to create a dynamic array not static array A [vector](http://www.cplusplus.com/reference/vector/vector/) might be what you're looking for

Member Avatar for tinstaafl
0
213
Member Avatar for Start4me

for a textbox this should work: For b As Integer = 0 To c z = x.Date.AddDays(b) TextBox1.Text = String.Concat(TextBox1.Text, b, vbNewLine) Next

Member Avatar for tinstaafl
0
291
Member Avatar for write.me

The simplest is probably the bubble sort, just as your instructor suggested. There's even a code snippets posted here for that type of sort.

Member Avatar for ddanbe
0
1K
Member Avatar for pandeter

if you loop through the items in the listview, possibly a For Each loop, you can compare the subitem to a date. You might have to parse it into a datetime type to do the comparison. If the date qualifies save the whole item in a separate list. This way …

Member Avatar for tinstaafl
0
316
Member Avatar for VictorK19

could you use a multidimensional array? string person[n][3] for (int i = 0; i < n; i++) { for (int j = 0; j < 3; j++) { inputfile >> person[i][j]; } } this way the sample from NathanOliver would look something like this // load the array with data …

Member Avatar for tinstaafl
0
199
Member Avatar for silversurf

if that is your goal then yes your code is backwards. your variables(xcode,xsprice, etc.) should be on the left side of the '=' and the subitems(?).text on the right side of the '='. By the same token it looks like you've repeated that mistake further on in your code. the …

Member Avatar for hyesin
0
1K
Member Avatar for cobaltfive

You could try something like this: #include "stdafx.h" #include <cstdlib> #include <iostream> #include <iomanip> using namespace std; int ValidateInput(string Message); int main() { int choice = 0; //to hold a menu choice double charges = 0; // to hold the monthly charges //const for air const double AIR = 1100.0, …

Member Avatar for tinstaafl
0
281
Member Avatar for pjns19

What could do is, in StrHTML12() check each element for an empty 'alt' attribute. Then process it from there. BTW, StrHTML12() is declared as a function but it doesn't return anything.

Member Avatar for tinstaafl
0
348
Member Avatar for tnputnam

Use the Split function to put the sentences from the paragraphs into 2 arrays. Then loop through the arrays to find common sentences.

Member Avatar for Reverend Jim
0
104
Member Avatar for nssrsaran

I think you've come to the wrong place. This is a place to help people with specific problems, mostly in code that they've already written. You need a site where you can hire a professional to do this. This is one such [site](http://www.codehire.com/). Unless of course you do have some …

Member Avatar for Gonbe
0
2K
Member Avatar for terrier_unknown

These might help: [Click Here](http://www.extremeoptimization.com/QuickStart/CSharp/NumericalDifferentiation.aspx) [Click Here](http://www.codeproject.com/Articles/3370/Complex-math-library-for-C-and-VB-NET)

Member Avatar for tinstaafl
0
319
Member Avatar for jangojan
Member Avatar for beanmiester

The End.