|
I didn't compose those, but you can get the LA times on-line under www.LAtimes.com. Today's puzzle is on page E13. Bill Cornwall writes very good articles.
The answer appears on the following Sunday, and last week's answer appeared today. You can also scroll back issues.
|
|
|
|
|
Hi
I need help in coding a login form that detects employee password and allocates them to department...I have the stock form, production form, sales form and managers form.
|
|
|
|
|
"detects"?
|
|
|
|
|
I have a problem when sending mail with SMTP protocol, if I want to send mail and the sender address is a hotmail or yahoo I can not send only with gmail account
|
|
|
|
|
Unfortunately those are the rules of the game; if you wish to send via the gmail server then you need a gmail account.
Unrequited desire is character building. OriginalGriff
I'm sitting here giving you a standing ovation - Len Goodman
|
|
|
|
|
Think about it for a second..
Why would Google waste electricity (time, money) on sending emails from competing services?
Bastard Programmer from Hell
|
|
|
|
|
i need a code for a 1 player die game..thanks!
|
|
|
|
|
Wonderful. Well good luck with that. Let us know how you get on with someone else doing your thinking for you.
Can you manage this breathing thing by yourself, or do you want some help with that?
|
|
|
|
|
Here is a link to a one player die game[^]
Ideological Purity is no substitute for being able to stick your thumb down a pipe to stop the water
|
|
|
|
|
Here ya go:
public static class Template
{
private static readonly System.Random randy = new System.Random() ;
private static string
Prompt
(
)
{
System.Console.Write ( "How many dice? " ) ;
return ( System.Console.ReadLine() ) ;
}
[System.STAThreadAttribute()]
public static int
Main
(
)
{
int result = 0 ;
try
{
string s = System.String.Empty ;
int i ;
while ( ( ( s = Prompt() ) != null ) && System.Int32.TryParse ( s , out i ) )
{
for ( ; i > 0 ; i-- )
{
System.Console.Write ( "{0} " , randy.Next ( 6 ) + 1 ) ;
}
System.Console.WriteLine() ;
}
}
catch ( System.Exception err )
{
System.Console.WriteLine ( err ) ;
}
return ( result ) ;
}
}
That wasn't so hard was it?
|
|
|
|
|
I am trying to bind a DataTable to MSChart using more than one Y value, I'd appreciate anyone pointing me in the right direction, an example, etc. Also, I need to bind the data not just add a point.
this.chart1.Series[strSeries].Points.DataBindXY(
dt.Tables["X"].Rows[nRec]["A"]), // X Value
dt.Tables["X"].Rows[nRec]["B"]), // Y Value
dt.Tables["X"].Rows[nRec]["C"]), // Y Value
dt.Tables["X"].Rows[nRec]["D"]), // Y Value
dt.Tables["X"].Rows[nRec]["E"]) // Y Value
);
I tried this and many other ways
this.chart1.DataSource = dt.Tables["X"];
this.chart1.Series[strSeries].XValueMember = "A";
this.chart1.Series[strSeries].YValueMembers = "B";
this.chart1.Series[strSeries].YValueMembers = "C";
this.chart1.Series[strSeries].YValueMembers = "D";
this.chart1.Series[strSeries].YValueMembers = "E";
this.chart1.DataBind();
Thanks in advance,
Michael
|
|
|
|
|
I have a project im working on, im trying to learn VS C# and i have chosen one of my old vb6 projects as a strating point.
I have downloaded the Aircraft instruments.net file
www.codeproject.com/Articles/27411/C-Avionic-Instrument-Controls
from this site as it provides me with the form controls i require. unfortunately the sporting chap who uploaded this fine code has not left any means of contacting them
my question is this how do i get from this demo program to actually adding the components from this application to the toolbox for use in my application
i have tried to google it but i dont really know what im looking for to find the solution.
If its not too much to ask could someone also please help me with parsing a text string which uses characters for heading (H) pitch (P) and roll (R) etc eg H124.5P0.1R0.0 where the first character is the start point and the next in line being the end character thus parsing the data from the string for each data block. again no look in finding a suitable example in c#
Thank you in advance
Regards
Jason
|
|
|
|
|
JTmetoo wrote: has not left any means of contacting them
Ummm, no. There is a forum for the article, which you have posted to. Whether the author responds is another matter.
Failure is not an option; it's the default selection.
|
|
|
|
|
|
how can we use #pragma omp directive in c# vs 2010??
|
|
|
|
|
|
its taking more execution time than sequential code.. any sol??
|
|
|
|
|
That is not possible; #pragma is a compiler directive and has nothing to do with execution speed.
Unrequited desire is character building. OriginalGriff
I'm sitting here giving you a standing ovation - Len Goodman
|
|
|
|
|
but i want to reduce the execution time of a loop by making it parllel...
for(int i=0;i<100;i++)
{
Console.WriteLine(i);
}
thatwhy i used pragma directive..
# prgma omp parllel
for(int i=0;i<100;i++)
{
Console.WriteLine(i);
}
but its increse the time instead of reducing..
any sol for this??
|
|
|
|
|
This has nothing to do with your original question, and I have already answered with a suggestion here[^].
KUNWAR999 wrote: # prgma omp parllel
What is this supposed to mean?
Unrequited desire is character building. OriginalGriff
I'm sitting here giving you a standing ovation - Len Goodman
|
|
|
|
|
Here[^] you go. Warning: it is a different world altogether.
|
|
|
|
|
Yes, I did discover that in the C++ compiler. My question was to get OP to explain what he/she thought it was, in terms of C#.
Unrequited desire is character building. OriginalGriff
I'm sitting here giving you a standing ovation - Len Goodman
|
|
|
|
|
A few points. That pragma is for C/C++. If you want to have the sequence in order, you shouldn't try to turn it parallel as there is no guarantee of order of execution in parallel processing. If this isn't an issue, why not use the Task Parallel Library.
|
|
|
|
|
You can't, so there is no answer to "how". The standard C# compiler does not support OpenMP.
|
|
|
|
|
i am using Pcap.net to send packets using send buffer with Wireshark file (pcap extension) and i want to do some packet manipulation e.g change the packet IP, but after send the packet again the packet looks corrupt with checksum bad and malformed TCP
using (PacketSendBuffer sendBuffer = new PacketSendBuffer((uint)capLength))
{
int numPackets = 0;
Packet packet;
while (inputCommunicator.ReceivePacket(out packet) == PacketCommunicatorReceiveResult.Ok)
{
IpV4Layer ipLayer = (IpV4Layer)packet.Ethernet.IpV4.ExtractLayer();
EthernetLayer ethernet = (EthernetLayer)packet.Ethernet.ExtractLayer();
var payload = packet.Ethernet.Payload.ExtractLayer();
IpV4Address newIpv4 = new IpV4Address("17.18.19.20");
ipLayer.Destination = newIpv4;
Packet newPacket = PacketBuilder.Build(DateTime.Now, ethernet, ipLayer, payload);
sendBuffer.Enqueue(newPacket);
++numPackets;
}
outputCommunicator.Transmit(sendBuffer, isSync);
}
|
|
|
|