|
What is your question?
Regards,
mav
--
Black holes are the places where God divided by 0...
|
|
|
|
|
How Do I check that the Vertical Scroll bar is shown.
o O º(`'·.,(`'·., ☆,.·''),.·'')º O o°
»·'"`»* *☆ t4ure4n ☆* *«·'"`«
°o O º(,.·''(,.·'' ☆`'·.,)`'·.,)º O o°
|
|
|
|
|
I was using Visual studio 2003 to develop windows applications in c#. Now I have moved to Visual studio 2005. I wanted to use Datagrid in my application but the only thing I see is what is called datagridview. Are these two the same, if yea can I use the same code to populate a datagridview?
phokojoe
|
|
|
|
|
|
They are not exactly the same. DataGridView replaced DataGrid in Dot net 2.0. Although DataGrid is still available for use. It is apparently not available through the IDE but you can still create a DataGrid in your code should you wish but you should considder using DataGridView instead.
[Modify]
You can add it to the IDE if you right-click on toolbox and select choose items.
|
|
|
|
|
DataGridView is the replacement for DataGrid, but they are not the same. The DataGridView doesn't support displaying data in a hierarchical manner.
The code you used to populate the DataGrid should work just fine to populate the DataGridView.
-----------------------------
In just two days, tomorrow will be yesterday.
|
|
|
|
|
Hi I'm having a problem with a Service i'm trying to write...
It seems like a simple problem but i'm getting nowhere...
I'm creating a windows service that will detect files that have been added to our local server dropbox, and then move and rename the files up to our hosted remote server.
We have a VPN connection to the hosted server, and can connect to the file structure with the internal IP address. however they are on seperate domains.
This means that i cannot have 1 User with Write access to both servers and need to impersonate the users with access.
Is this possible? I have been trying and failing to use CredentialCache with NetworkCredential and LoginUser!
Has anyone got any ideas?
Thanks
Martin
|
|
|
|
|
Hi,
The NetworkCredential does not support public-key based authentication methods such as Secure Sockets Layer(SSL) client authentication.
You can check this with your VPN connection.
One more thing, why do you want to have write access at the local server for the same user ?
Manoj
|
|
|
|
|
Hi Manoj,
I needed Read/Write access To move files in both directions with the service. We have now decided to approach this in a different way, intergating it with an exsisting service, adding a webservice to accept and serve files!
Thanks for you help anyway.
Martin
|
|
|
|
|
|
blackjack2150 wrote: my application cracked and somehow I ended up with this on
Reallly!! I keep seeing this everyday that I thought it was on of VS2005 features;P
Smile: A curve that can set a lot of things straight!
(\ /)
(O.o)
(><)
|
|
|
|
|
I want to display an image in my custom control.For that i used
Image.FromFile(pathofimage)...But this statement gave an out of memory error.
This happened when i changed an xml file to format 'bmp' and loaded that image.When i saw the file it had a red crossed symbol. How can i check whether an image file is a valid image file or not?..Please help....
|
|
|
|
|
Hi,
The function "Image.FromFile" can through 2 types of Exceptions.
1)OutOfMemoryException
2)FileNotFoundException
The first exception "OutOfMemoryException" will be thrown when the file does not have a valid image format. Hence, you put the above line in a try-catch block. There is problem with file format, when you get an exception type as OutOfMemoryException.
Manoj
|
|
|
|
|
snoby wrote: when i changed an xml file to format 'bmp'
Why did you change the format of file ?
Thanks and Regards
Sandeep
If If you look at what you do not have in life, you don't have anything,
If you look at what you have in life, you have everything... "
|
|
|
|
|
Explain how you "changed an XML file to format BMP"??
|
|
|
|
|
While testing with my custom control...testers tried to rename an Xml file to Bmp file.In that extreme case , my custom control should not fail. So while fetching such a file my control failed.I can handle it in try -catch block.This i have already done.But is there any coding to restrict such exceptions from occuring ?
|
|
|
|
|
snoby wrote: testers tried to rename an Xml file to Bmp file.
Of course that's not going to work...
snoby wrote: In that extreme case , my custom control should not fail. So while fetching such a file my control failed.I can handle it in try -catch block.
That's exactly what you have to do.
snoby wrote: But is there any coding to restrict such exceptions from occuring ?
You can't predict the future. You have no choice but to handle that exception. Even if the file is intentioned to be a valid image, files CAN be corrupted, no matter what you do. You simply don't have a choice here. You MUST handle the exception.
|
|
|
|
|
Hi friends..
string str="ABC";
this means that we are assigning value to the object str of string class..right?But whn we are instantiating some class then we are assigning values to the feilds of that class(ex:Employee_1.Name="xyz",Employee_1.Id=1234,etc where Employee_1 is an object of class Employee)..thn how things are working differently for string class..I think this has to do something with user defined and predefined reference data types..
|
|
|
|
|
All reference types are the same, regardless if the type is user defined or "predefined".
|
|
|
|
|
Literal "ABC" IS instance of type string.
"Throughout human history, we have been dependent on machines to survive. Fate, it seems, is not without a sense of irony. " - Morpheus
"Real men use mspaint for writing code and notepad for designing graphics." - Anna-Jayne Metcalfe
|
|
|
|
|
Hi,
Even your question is not very clear
Let me explain you the difference between the predefined and user defined data types.
See if "AA" is a user defined class, while creating an instance of the classs AA, "new" operator must be used. i.e.
AA a = new AA();
Only, after this we can set/get the non-static members.
In case of predfined types like "string", the C# compiler knows of them advance, hence uses "new" operator internally. i.e.
In case of
string str = "ABC";
C# compiler knows about string class, hence does str = new string("ABC") internally.
Manoj
|
|
|
|
|
|
Thanks for such short and sweet answer..nw i understood.
|
|
|
|
|
The only special about strings, is that you can write string literals in the code. When the code is compiled, the string literals are created as constant string objects.
So, this code:
string str = "ABC";
works more like this:
const string strconst001 = "ABC";
string str = strconst001;
So, when you assign a string literal, you don't really create a string object, you only assign the reference of a string object that already exists.
When you actually create a new string object, it works like any other class. Example:
string str = new String('*', 42);
---
single minded; short sighted; long gone;
|
|
|
|
|
Hi
Im designing a touch screen windows application where i have customized the buttons to hold images for all states like (enabled, disabled, clicked, mouse over). Same i have done for panels. But some times the images are not displaying correctly instead of image it is displaying Big X mark in red color. (like in the internet explorer if the image is not present it will diaply one X mark right)
Why did this happend, I have not seen this regularly, this is happened rarely..
I am thinking it should be a memory issue.. or GUI is not refreshing properly?
Even i have used double buffering..
One more question Is there anyway to get notificaiton (like events) in the code if the user kills the application from task manager? Becuase sometimes application is not opening if we kill the application using taskmanager and reopen.
Any help?
|
|
|
|