|
No conversion program is perfect. IF you posted the code in question, perhaps we could help.
Christian Graus
Please read this if you don't understand the answer I've given you
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Is there a way to view the contents of a merge module through VS.NET or through some other free viewing tool?
|
|
|
|
|
|
|
Also the Files property in the setup project provides a popup that lists the files.
|
|
|
|
|
hi
i add a grid in my wpf window and load data from database.
now i want to bind grid control to dataTable, but i didn't found any DataSource property in Grid, how to bind it to display data ?
thanks
|
|
|
|
|
The Grid can't bind to a datasource. You can set the DataContext of the grid but then you have to create the layout etc and all the handlers for adding new rows etc.
If you are looking for a replacement for the DataGrid which is what I suspect you're after then Xceed give away a capable datagrid[^] for free which will do what you want.
I doubt it. If it isn't intuitive then we need to fix it. - Chris Maunder
|
|
|
|
|
Hello, I am new at C# and I am having difficulty 'starting' to write a program I am working on because I can't find any good resources on the WWW to answer my two questions.
Can anyone recommend some relief for me?
Here is what I have.
I want to save some test data is xml and generate a html report from the data. I seems like an xsl is the way to do this but I am not real sure how to read write xsl/xml and generate a report in html with Visual Studio 2008?
Does anyone know of any easy to understand examples, on how to do this.
I think it would also be useful to use linq to select values in the xml file and process them first.
Thanks for your help.
|
|
|
|
|
Try here, I started doing XML/XSLT reports and this has good info for beginners.
http://www.w3schools.com/[^]
What was the SerialPort question?
Scott P
“It is practically impossible to teach good programming to students that have had a prior exposure to BASIC: as potential programmers they are mentally mutilated beyond hope of regeneration.”
-Edsger Dijkstra
|
|
|
|
|
Hi there,
After reading msdn, looking for answers in google and testing a lot of different things, I gave up and now I'm here hoping for an answer.
The Problem:
I'm having a big problem trying to delete a row from a DataTable wich is related to its father. The exception I'm receiving is "Null Reference exception" (or something like that, my visual studio isn't in english)
The structure:
DataSet dsData contains:
DataTable dtbClients -> PrimaryKey: 'MotherAccount'
DataTable dtbAccounts -> PrimaryKey: 'ClientName'
DataTable dtbProducts -> PrimaryKey: 'CodeProduct'
Wich are related like this:
dtbClientes -> dtbAccounts (through column 'MotherAccount')
dtbAccounts -> dtbProducts (through column 'ClientName')
The data:
In this specific case, dtbClients has only 1 client wich has 1 account (in dtbAccounts) with no products.
What am I tried to do:
First I tried to remove the client directly because I though that the cascade constraint automatically created when we make a relation would take care of deleting the associated row in dtbAccounts. But that didn't happend.
The application threw and Null Referenec exception, and the stackTrace pointed to a function with 'Cascade' in its name.
Question 1): Is it possible to fix this exception and make c# delete everything associated to the removed client?
Well, with this exception I quited trying to delete the client directly and tried something else.
This time I'm removing the account related to the client first, this way when deleting the client there would be no problems since there are no rows related to it (I've no problems deleting clients with no accounts associated).
The problem:
It gives me the same Null Reference exception when trying to delete the account first! And it doesn't have any product related to it. My guess is that somehow the parent row(client) is related to it, so I can't delete it.
Question 2): How do I delete this account?
Can anyone help me with this ?
I hope I was clear enough.
Thanks in advance!
Oscar
|
|
|
|
|
Oh, another thing,
What I'm trying to do over there is actually one part of a mergin process of 2 datatables.
Actually is not a merge, it is an update.
The old dataset will be updated to look exactly like the new one, wich means that new rows will be added, old rows will be updated and old rows will be removed.
Well, I've just discovered the DataSet.Merge(DataSet) function and it is quite usefull.
The problem is that it doesn't seem to remove old rows in the target dataset that are not in the (updated version) source dataset.
Is there a way to do this not manually? A function? A property? I don't know... something that would make the Merge function delete rows from the target dataset.
Thanks in advance!
Oscar
|
|
|
|
|
Can no one help me with this ?
Thanks
Oscar
|
|
|
|
|
Hello,
1) What is the best way to check the anonymous proxy?
2) How to check whether a particular proxy server is enabled SSL or not?
Let's say there is a list of anonymous proxies [^]. I wanna check which server is up and running and which server is enabled SSL...
How can I do that?
Initially, I was thinking to use "My.Computer.Network.Ping(url)" method but we can't specify the port so that I can't use it in my case.. What about WebRequest?
In this page[^], they wrote like below
What is a free proxy checker?
Free service trying to provide daily updated list of public HTTP proxy servers. Usually provide small list of proxies with low percent of functioning servers due to hosting restrictions on CPU time (they simply can't allow themselves to check many proxies every second especially in parallel).
So, I believe that there are some ways to check the proxy server and SSL..
Any idea? Thanks in advance
|
|
|
|
|
Which platform (asp.net or C# client)?
|
|
|
|
|
Bert delaVega wrote: Which platform (asp.net or C# client)?
Either one is okay for me.
|
|
|
|
|
Try using Tcpclient to connect to the listed ports. That'll give you an indication if the proxy is active or not.
Namespace: System.Net.Sockets
|
|
|
|
|
thanks.
#1) Will it be worked with URL?
#2) How can I check whether a particular server is enabled SSL or not?
|
|
|
|
|
private Bitmap rotateImage(Bitmap b, float angle)
{
Bitmap bmp1 = new Bitmap(b.Width, b.Height);
Graphics g = Graphics.FromImage(bmp1);
g.TranslateTransform((float)b.Width / 2, (float)b.Height / 2);
//rotation
g.RotateTransform(angle);
g.TranslateTransform(-(float)b.Width / 2, -(float)b.Height / 2);
g.DrawImage(b, new Point(0, 0));
return bmp1;
}
I found this code in a site..This deals with Rotating an image..
But when i crop with this... Image is getting vanished on its edges..
How to perform rotation without any modifications in the image size? Any modidications in this or any clues?
|
|
|
|
|
If you rotate an image, unless it's a square the dimensions will change, only the area stays constant.
Luckie wrote: Bitmap bmp1 = new Bitmap(b.Width, b.Height);
The problem is above.
You'll need to size the image appropriately, guarenteeing enough room for a rotated image to fit. At the very least the size will need to be a square of the largest dimension of the original image. You can crop the image appropriately afterwards.
I'm largely language agnostic
After a while they all bug me
|
|
|
|
|
MidwestLimey wrote: You'll need to size the image appropriately, guarenteeing enough room for a rotated image to fit. At the very least the size will need to be a square of the largest dimension of the original image. You can crop the image appropriately afterwards.
Don't get you mate
|
|
|
|
|
If for instance you have a 5x9 image, to rotate 90 or 270 degrees you would need a square of 9x5 for the resulting image to fit. Since it needs to also hold the original image it would need to be 9x9. If you're rotating by some discreet amount (see post below), you'll need to calculate how much room you'll need, size the original image appropriately and then resize the image afterwards to your required dimensions.
I'm largely language agnostic
After a while they all bug me
|
|
|
|
|
MidwestLimey wrote: you'll need to calculate how much room you'll need, size the original image appropriately and then resize the image afterwards to your required dimensions.
Any other way?
Don't try to make someone love you..Try to be the one who can be loved...
|
|
|
|
|
Can u just modify it in the coding and reply or just quote the lines to be modified..
Don't try to make someone love you..Try to be the one who can be loved...
|
|
|
|
|
MidwestLimey wrote: You'll need to size the image appropriately, guarenteeing enough room for a rotated image to fit. At the very least the size will need to be a square of the largest dimension of the original image. You can crop the image appropriately afterwards.
No, the largest it would need to be is the length of the diagonal (for a rotation that lays a diagonal along the X or Y axis). (x^2+y^2)^.5
You know, every time I tried to win a bar-bet about being able to count to 1000 using my fingers I always got punched out when I reached 4....
-- El Corazon
|
|
|
|
|
Ya, my frazzled mind was stuck on 90 degrees
I'm largely language agnostic
After a while they all bug me
|
|
|
|