Click here to Skip to main content
15,895,142 members
Home / Discussions / C#
   

C#

 
GeneralRe: Code style Pin
Lutosław28-Jun-11 8:08
Lutosław28-Jun-11 8:08 
NewsNOTE 3 ,4 Pin
Lutosław28-Jun-11 0:48
Lutosław28-Jun-11 0:48 
AnswerRe: Code style [modified] Pin
PIEBALDconsult28-Jun-11 3:09
mvePIEBALDconsult28-Jun-11 3:09 
AnswerRe: Code style Pin
SledgeHammer0128-Jun-11 7:34
SledgeHammer0128-Jun-11 7:34 
GeneralRe: Code style Pin
Lutosław28-Jun-11 8:04
Lutosław28-Jun-11 8:04 
GeneralRe: Code style Pin
SledgeHammer0128-Jun-11 8:51
SledgeHammer0128-Jun-11 8:51 
GeneralRe: Code style Pin
Lutosław28-Jun-11 9:47
Lutosław28-Jun-11 9:47 
QuestionCreating a multidimensional array from class Pin
lada_vyvojar27-Jun-11 20:34
lada_vyvojar27-Jun-11 20:34 
Hello,
There Service07.Eso9PortClient class that contains method getOrders () which returns an array of orders.
Each order contains information (address, folders, etc.).

I need to convert these orders into an array or collection so that I could browse and handle these orders.
Could someone advise me how to do it?

/ / Order to convert the array or collection / /

/ / Orders
Service07.Eso9PortClient orderClient07 Service07.Eso9PortClient = new ();
Service07.Order [] orders = orderClient07.getOrders ();
foreach (Service07.Order order in orders)
{
/ / Order addresses
Service07.Address [] addresses = order.Addresses;
foreach (Service07.Address address in addresses)
{
/ / Addresses attributes
Service07.Attribute [] = addressAttributes address.Attributes;
foreach (Service07.Attribute addressAttribute in addressAttributes)
{
string = addressAttributeName addressAttribute.Name;
string = addressAttributeValue addressAttribute.Value;
}
string = addressCity address.City;
string = addressCompany address.Company;
string = addressCountry address.Country;
}

/ / Order attributes
Service07.Attribute [] = orderAttributes order.Attributes;
foreach (Service07.Attribute orderAttribute in orderAttributes)
{
string = orderAttributeName orderAttribute.Name;
string = orderAttributeValue orderAttribute.Value;
}

/ / Order Coupon
string = orderCouponCode order.Coupon! = null? order.Coupon.Code: null;
string = orderCuponValue order.Coupon! = null? order.Coupon.Value: null;

/ / Order Created
string = orderCreated order.Created;

/ / Order items
Service07.OrderItem [] items = order.Items;
foreach (Service07.OrderItem item in items)
{
string itemName = item.Name;
string = itemNote item.Note;
}
}

// Result should look something like this
string ... myArray = new ...
foreach (string in order myArray)
{
foreach (string address in myArray...)
{
....
}
}
Unfortunately I do not know how to declare a field and set Frown | :-(

Thank you for your answer
AnswerRe: Creating a multidimensional array from class Pin
Mario Majčica27-Jun-11 23:29
professionalMario Majčica27-Jun-11 23:29 
QuestionRead from Byte Array Pin
DJ24527-Jun-11 20:04
DJ24527-Jun-11 20:04 
AnswerRe: Read from Byte Array Pin
Pete O'Hanlon27-Jun-11 21:49
mvePete O'Hanlon27-Jun-11 21:49 
AnswerRe: Read from Byte Array Pin
Mario Majčica27-Jun-11 23:31
professionalMario Majčica27-Jun-11 23:31 
AnswerRe: Read from Byte Array Pin
BobJanova27-Jun-11 23:52
BobJanova27-Jun-11 23:52 
GeneralBitConverter Endianness Pin
dybs28-Jun-11 12:56
dybs28-Jun-11 12:56 
GeneralRe: BitConverter Endianness Pin
BobJanova28-Jun-11 13:12
BobJanova28-Jun-11 13:12 
GeneralRe: Read from Byte Array Pin
DJ24528-Jun-11 23:57
DJ24528-Jun-11 23:57 
GeneralRe: Read from Byte Array Pin
lukeer29-Jun-11 0:05
lukeer29-Jun-11 0:05 
GeneralRe: Read from Byte Array Pin
DJ24529-Jun-11 0:23
DJ24529-Jun-11 0:23 
QuestionGet one type of elements from dictionary Pin
Mc_Topaz27-Jun-11 3:01
Mc_Topaz27-Jun-11 3:01 
AnswerRe: Get one type of elements from dictionary Pin
musefan27-Jun-11 3:08
musefan27-Jun-11 3:08 
GeneralRe: Get one type of elements from dictionary Pin
Mc_Topaz27-Jun-11 3:16
Mc_Topaz27-Jun-11 3:16 
GeneralRe: Get one type of elements from dictionary Pin
BobJanova27-Jun-11 3:56
BobJanova27-Jun-11 3:56 
AnswerRe: Get one type of elements from dictionary Pin
Keith Barrow27-Jun-11 3:28
professionalKeith Barrow27-Jun-11 3:28 
GeneralRe: Get one type of elements from dictionary Pin
David198727-Jun-11 4:01
David198727-Jun-11 4:01 
AnswerRe: Get one type of elements from dictionary Pin
Ian Shlasko27-Jun-11 9:43
Ian Shlasko27-Jun-11 9: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.