Click here to Skip to main content
15,895,084 members
Home / Discussions / Algorithms
   

Algorithms

 
GeneralRe: finding the best algorithm Pin
YvesDaoust3-Dec-12 0:15
YvesDaoust3-Dec-12 0:15 
GeneralRe: finding the best algorithm Pin
YvesDaoust2-Dec-12 21:40
YvesDaoust2-Dec-12 21:40 
QuestionSplitting up multiple readings... Pin
glennPattonWork39-Oct-12 0:50
professionalglennPattonWork39-Oct-12 0:50 
GeneralRe: Splitting up multiple readings... Pin
harold aptroot9-Oct-12 0:57
harold aptroot9-Oct-12 0:57 
GeneralRe: Splitting up multiple readings... Pin
glennPattonWork39-Oct-12 1:27
professionalglennPattonWork39-Oct-12 1:27 
GeneralRe: Splitting up multiple readings... Pin
harold aptroot9-Oct-12 1:35
harold aptroot9-Oct-12 1:35 
GeneralRe: Splitting up multiple readings... Pin
Pete O'Hanlon9-Oct-12 2:05
mvePete O'Hanlon9-Oct-12 2:05 
GeneralRe: Splitting up multiple readings... Pin
glennPattonWork39-Oct-12 2:36
professionalglennPattonWork39-Oct-12 2:36 
Hmmm, the evil gods Malloc() & Calloc(), but I have already discovered that. The ultimate goal is to split the readings into separate files from the text property of a text box ie the box has output from the hand held in one rtb I was looking for a way to split the contents up. If the readings are say 12345678|AAA|BBBB|CCCCCC the next reading is 23456781|AAA|BBBB|CCCC at the moment the file is created with all the readings in one place. What I'm trying to is split up the data to separate files as the spec does say to do it that way but I can see problems with it if don't have a method, if I create the string array with the total number of records read from the unit that would get around that problem. If I use substring() as below:

C#
foreach (string subString in rtbTestBox.Text.Split('\n'))
          {

           //   MessageBox.Show(subString);
              // need to get string length 7 (8 bit) and compare the same

              foreach (string subStringSerNo in subString.Split('|'))
              {
                  //MessageBox.Show("here 3!");
                  if (subStringSerNo.Length == 7)
                  {
                      Serial_Numbers[serialNumberIndex] = subString;
                      MessageBox.Show(subString);
                      MessageBox.Show("Yaowwwser!!!", "", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
                      serialNumberIndex++;
                  }
              }

and it should give me an array of readings which I can the search for differences in the serial number. If I then have the array of strings, the serial number is different I can place it in a different string if it's the same just append it.

Am I making any sense in my caffeine addled state!
Glenn
GeneralRe: Splitting up multiple readings... Pin
Pete O'Hanlon9-Oct-12 2:45
mvePete O'Hanlon9-Oct-12 2:45 
GeneralRe: Splitting up multiple readings... Pin
Jochen Arndt9-Oct-12 3:09
professionalJochen Arndt9-Oct-12 3:09 
GeneralRe: Splitting up multiple readings... Pin
glennPattonWork39-Oct-12 4:34
professionalglennPattonWork39-Oct-12 4:34 
GeneralRe: Splitting up multiple readings... Pin
Jochen Arndt9-Oct-12 4:45
professionalJochen Arndt9-Oct-12 4:45 
GeneralRe: Splitting up multiple readings... Pin
glennPattonWork39-Oct-12 5:15
professionalglennPattonWork39-Oct-12 5:15 
GeneralRe: Splitting up multiple readings... Pin
Jochen Arndt9-Oct-12 5:55
professionalJochen Arndt9-Oct-12 5:55 
GeneralRe: Splitting up multiple readings... Pin
glennPattonWork39-Oct-12 4:45
professionalglennPattonWork39-Oct-12 4:45 
GeneralRe: Splitting up multiple readings... Pin
Eddy Vluggen22-Oct-12 6:24
professionalEddy Vluggen22-Oct-12 6:24 
QuestionPuzzle 8 Solving with bfs Pin
mohammadkaab25-Sep-12 22:50
mohammadkaab25-Sep-12 22:50 
AnswerRe: Puzzle 8 Solving with bfs Pin
Alan Balkany26-Sep-12 4:27
Alan Balkany26-Sep-12 4:27 
GeneralRe: Puzzle 8 Solving with bfs Pin
mohammadkaab26-Sep-12 4:38
mohammadkaab26-Sep-12 4:38 
GeneralRe: Puzzle 8 Solving with bfs Pin
Alan Balkany26-Sep-12 4:42
Alan Balkany26-Sep-12 4:42 
GeneralRe: Puzzle 8 Solving with bfs Pin
mohammadkaab26-Sep-12 5:01
mohammadkaab26-Sep-12 5:01 
GeneralRe: Puzzle 8 Solving with bfs Pin
Alan Balkany26-Sep-12 5:09
Alan Balkany26-Sep-12 5:09 
GeneralRe: Puzzle 8 Solving with bfs Pin
mohammadkaab26-Sep-12 21:36
mohammadkaab26-Sep-12 21:36 
QuestionBit Interleaver Pin
Skippums24-Sep-12 16:07
Skippums24-Sep-12 16:07 
QuestionImage processing Pin
fabio_antonio23-Sep-12 8:25
fabio_antonio23-Sep-12 8:25 

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

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