Click here to Skip to main content
15,888,263 members
Home / Discussions / C#
   

C#

 
QuestionCreating Registry Keys with Setup if key doesn't exist. Pin
Paramhans Dubey21-Sep-09 2:50
professionalParamhans Dubey21-Sep-09 2:50 
AnswerRe: Creating Registry Keys with Setup if key doesn't exist. Pin
Manas Bhardwaj21-Sep-09 3:24
professionalManas Bhardwaj21-Sep-09 3:24 
GeneralRe: Creating Registry Keys with Setup if key doesn't exist. Pin
Paramhans Dubey21-Sep-09 19:06
professionalParamhans Dubey21-Sep-09 19:06 
QuestionReportViewer control problem Pin
firefeet21-Sep-09 1:23
firefeet21-Sep-09 1:23 
AnswerRe: ReportViewer control problem Pin
Abhishek Sur21-Sep-09 11:42
professionalAbhishek Sur21-Sep-09 11:42 
GeneralRe: ReportViewer control problem Pin
firefeet21-Sep-09 18:16
firefeet21-Sep-09 18:16 
QuestionHow to delete outlook appointment Pin
tspradeep198021-Sep-09 1:06
tspradeep198021-Sep-09 1:06 
Questionsplitting values randomly - C# Pin
flower_t21-Sep-09 1:05
flower_t21-Sep-09 1:05 
I have a set of values based on which i have split the string

string[] seperator = new string[9];
seperator[0] = "*"; //is the client
seperator[1] = "/"; //is the name of company
seperator[2] = "("; //name of the market
seperator[5] = ":"; //ID
seperator[6] = "?"; //orderType
seperator[3] = "!@"; //realtive Time
seperator[4] = "!+"; //
seperator[7] = "+"; //quantity
seperator[8] = "@";//price
string[] result = values.Split(seperator, StringSplitOptions.None);


For example: The input string is
*A/AB(M!@12:6?SIMPLE!+5+2


OUTPUT
[0]: ""
[1]: "A"
[2]: "AB"
[3]: "M"
[4]: "12"
[5]: "6"
[6]: "SIMPLE"
[7]: "5"
[8]: "2"



For example: The input string is
*A(M!@12?SIMPLE!+5+2/AB:6

OUTPUT:
[0]: ""
[1]: "A"
[2]: "M"
[3]: "12"
[4]: "SIMPLE"
[5]: "5"
[6]: "2"
[7]: "AB"
[8]: "6"


The problem I am facing is : how can I relate that A is the client, AB is the company..etc etc

as the order in which the user can enter this information RANDOM...
If he doesnot enter any one of these values, it changes the result length ?


Thanks in advance
AnswerRe: splitting values randomly - C# [modified] Pin
Calla21-Sep-09 1:29
Calla21-Sep-09 1:29 
AnswerRe: splitting values randomly - C# Pin
OriginalGriff21-Sep-09 2:46
mveOriginalGriff21-Sep-09 2:46 
AnswerRe: splitting values randomly - C# Pin
flower_t21-Sep-09 2:56
flower_t21-Sep-09 2:56 
GeneralRe: splitting values randomly - C# Pin
harold aptroot21-Sep-09 3:38
harold aptroot21-Sep-09 3:38 
GeneralRe: splitting values randomly - C# Pin
PIEBALDconsult21-Sep-09 7:39
mvePIEBALDconsult21-Sep-09 7:39 
AnswerRe: splitting values randomly - C# Pin
Luc Pattyn21-Sep-09 4:10
sitebuilderLuc Pattyn21-Sep-09 4:10 
AnswerRe: splitting values randomly - C# Pin
PIEBALDconsult21-Sep-09 4:57
mvePIEBALDconsult21-Sep-09 4:57 
GeneralRe: splitting values randomly - C# Pin
Luc Pattyn21-Sep-09 5:40
sitebuilderLuc Pattyn21-Sep-09 5:40 
GeneralRe: splitting values randomly - C# Pin
OriginalGriff21-Sep-09 5:52
mveOriginalGriff21-Sep-09 5:52 
GeneralRe: splitting values randomly - C# Pin
PIEBALDconsult21-Sep-09 6:11
mvePIEBALDconsult21-Sep-09 6:11 
GeneralRe: splitting values randomly - C# [modified] Pin
PIEBALDconsult21-Sep-09 7:22
mvePIEBALDconsult21-Sep-09 7:22 
GeneralRe: splitting values randomly - C# Pin
Luc Pattyn21-Sep-09 7:50
sitebuilderLuc Pattyn21-Sep-09 7:50 
GeneralRe: splitting values randomly - C# Pin
OriginalGriff21-Sep-09 5:48
mveOriginalGriff21-Sep-09 5:48 
GeneralRe: splitting values randomly - C# Pin
PIEBALDconsult21-Sep-09 7:42
mvePIEBALDconsult21-Sep-09 7:42 
AnswerRe: splitting values randomly - C# Pin
PIEBALDconsult21-Sep-09 7:50
mvePIEBALDconsult21-Sep-09 7:50 
QuestionMicrosoft Document Explorer is driving me CRAZY Pin
Axonn Echysttas21-Sep-09 0:07
Axonn Echysttas21-Sep-09 0:07 
AnswerRe: Microsoft Document Explorer is driving me CRAZY Pin
Alan N21-Sep-09 1:43
Alan N21-Sep-09 1:43 

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.