|
PaulC1972 wrote:
Yep. I'll be teaching a course at a local community college this fall and I hope I don't find my problems floating around here.
why? some cheaters are inevitable, given the choice I'd prefer ones that are easy to catch.
|
|
|
|
|
dan neely wrote: given the choice I'd prefer ones that are easy to catch
Yep. When I was a graduate student, there was once some class that was exiting the room where my class was entering. The teacher had caught this kid cheating and was telling him that he was going to get him expelled from the university. I thought the teacher was going overboard, but when I think of it, I'd probably do the same.
|
|
|
|
|
|
From the link:
"If I did your homework for you, then you might pass your class without learning how to write a program like this. Then you might graduate and get your degree without learning how to write a program like this. You might become a professional programmer without knowing how to write a program like this. Someday you might work on a project with me without knowing how to write a program like this. Then I would have to do you serious bodily harm." [Thanks to Jack Klein]
The last two sentences sound like signature material
|
|
|
|
|
|
divaa wrote: could u anybody please send algorithm/c# code for the given FROG Puzzle
Ummm, exercise some brain cells and do it yourself. If you are stumped, then ask a question. Nobody sends algorithms for the heck of it
|
|
|
|
|
divaa! i am so sad. i give you homework for college degree and you fail me by asking cpian. now you get black grade.
sincerely your college professor
Sincelery yours, Computer Information conSciences Professor and grader, Sharada Ulhas
|
|
|
|
|
Haven't seen you in a long time smacking on people for asking homework questions
|
|
|
|
|
Yes, I took him for a vacation. He's back now.
|
|
|
|
|
Hello my fellow CPians.
I have read articles on creating templates and user controls but I dont think that will solve my problem, so I figure what better place to ask then here?
The best way for me to explain my problem is with an example.
Lets say I have a widgit.
This widgit has 3 pieces, each piece has it's own characteristics..
What I would like to do:
The Page will bring up general information about the widgit it's self.
Then under that a multipage strip with a tab for each piece.
Click on the tab and a Page gets generated using a template page with the controls and eye candy required. These generated pages will need to interact with the server to get and update information.
Is it possible to create a template page that has all the controls I need then use that page to generate new pages on the fly? I really dont want to have to keep re-writing the same code over and over again. Each page will be exactly the same.
Thank you for your help,
Will O'Malley
I hate users. Not all of them, just the ones who talk.CP member: Al Einstien
|
|
|
|
|
OMalleyW wrote: Each page will be exactly the same.
Guess I don't really understand what it is you are asking for?
only two letters away from being an asset
|
|
|
|
|
I think I have answered my question by trying to explain what I wanted to do.
Thank you for getting back to me soo soon.
Will
I hate users. Not all of them, just the ones who talk.CP member: Al Einstien
|
|
|
|
|
Hi!
I have a few instances (say 10) of a UserControl, each with 5 properties, on a Form. I want to implement a "Copy From" function that works the following way:
1. The user can right click on any UserControl. The right click menu allows the user to select a Copy From menu item which springs up a ToolStripComboBox with a list of other similar controls.
2. Once the user selects an instance of the UserControl in the ToolStripComboBox, that UserControl's properties are to be copied to the current UserControl.
Each UserControl has a ControlID property that is unique to it (listed in an eControlID enum.) This property will not be copied over. However, the ToolStripComboBox is populated with all the IDs (say A...Z) to help the user identify the UserControl whose properties he wants copied.
I have got this far:
<br />
private void ContextMenuCopyFrom_SelectedIndexChanged(object sender, EventArgs e)<br />
{<br />
this.ControlID= (eControlID)ContextMenuCopyFrom.SelectedIndex; <br />
}<br />
How do I actually figure out which UserControl has been selected to copy from and then copy the properties.
I figure it'll be something like
<br />
this.Property1 = UserControlSelected.Property1;<br />
this.Property2 = UserControlSelected.Property2;<br />
|
|
|
|
|
You can go through the Controls collection of the form and check the type of control.
If the control is of the same type of your user control, match the ControlId with the controlId selected in the combo.
If matches, thats the control user wanted.
Every bit counts ADD
|
|
|
|
|
Is there any way of doing this without using a collection of controls? Can I match the SelectedIndex to a member of the enum and then copy the properties of that particular object?
|
|
|
|
|
Hi All,
i found an article posted by Mr. Fabian on email sending.
http://www.codeproject.com/cs/internet/WinEmailClient.asp#__comments
it is working perfectly when i compile this program. But there is a system.web.mail namespace in this windows app, which is not possible to write in my windows appl. but i can use it in his program. Why? Anyone please help me, because i need this program.
Ali
|
|
|
|
|
Could not understand the question.
If it is compiling then where is hte problem?
Every bit counts
ADD
|
|
|
|
|
i will explain...
i downloaded the code, saved in a local directory, clicked on .csproject file, and run the program, it works and i could send mail.
then i created a new windows app, tried to include system.web.mail namespace in it, but i cant ( when i press ctrl+space after system.web, i get nothing.) but when i press ctrl+space after system.web in his program, i get web.mail. We both have done windows program. Do i need to set anything more?
|
|
|
|
|
You probably are missing reference to System.Web assembly.
Go to Solution exporer, veiw the references under the project, if you dont find System.Web listed there, Add it.
Every bit counts ADD
|
|
|
|
|
|
Thanks ADD and judah, it was correct. i am just a fresher in .net.
Thanks again.
bye
|
|
|
|
|
I'm having trouble reading data into a strongly typed dataset from an XmlReader where the data is held as attributes rather than elements. I retrieve two document types and have an XSD for each. One is a standard results document and the other is an error one, formatted as:
results:
<?xml version="1.0" encoding="ISO-8859-1" ?>
<result id="123" generated="3456789" account_id="1">
<field1>FIELD1DATA</field1>
<field2>FIELD2DATA</field2>
<field3 />
</result>
error:
<?xml version="1.0" encoding="ISO-8859-1" ?>
<result error="001" severity="1" message="Record not in database" />
I'm able to populate my dataset from the 'results' XML doc without any problems (and can read the attributes as well) but the 'error' XML doc doesn't populate any rows into the dataset, even though the XSD defines the attributes as data fields:
<?xml version="1.0" encoding="utf-16"?>
<xs:schema xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" xmlns:b="http://schemas.microsoft.com/BizTalk/2003" id="ResultError" xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="result">
<xs:complexType>
<xs:attribute name="error" type="xs:string" />
<xs:attribute name="severity" type="xs:string" />
<xs:attribute name="message" type="xs:string" />
</xs:complexType>
</xs:element>
<xs:element msdata:IsDataSet="true" msdata:UseCurrentLocale="true" name="ResultError">
<xs:complexType>
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element ref="result" />
</xs:choice>
</xs:complexType>
</xs:element>
</xs:schema>
Can anyone shed any light on this? The worst case I can figure is that the ReadXml() function reads the InnerXml property rather than the OuterXml one and therefore discards the attributes but I can't believe that this is actually right...
Thanks in advance
D
|
|
|
|
|
I have a task to deploy a multistate treenode that will display disabled text if the user is not authorized to modify/view the contents of the treenode item.
I have everything implemented. But I was wondering if anyone knows of the "standard" for displaying disabled text in a control. I assume first off that the text background color = the control background color. But what should the ForeColor be set to? SystemColors.? I was hoping there was a SystemColors.DisabledText.....but no luck. Has anyone done this?
-- modified at 10:37 Friday 21st July, 2006
|
|
|
|
|
Try this
System.Windows.Forms.ControlPaint.DrawStringDisabled()
with color
SystemColors.ControlLightLight
or
SystemColors.Control
Every bit counts
ADD
|
|
|
|
|
Hi all,
is there a simple way to sort dates in a listbox with the dd.mm.yyyy format, so that the dates are shown in correct asscending order ?
tnx
|
|
|
|