|
-
Jul 19th, 2005, 08:13 PM
#1
Thread Starter
Frenzied Member
Location() property
I don't normally code in asp.net...I do mainly desktop apps with vb.net
I'm trying to grab the location of a control at run-time but the Location property doesn't seem to exist.
What's a way to capture the upper left corner and lower right corner of a control?
-
Jul 20th, 2005, 12:51 AM
#2
Re: Location() property
I think you should explain what you're trying to do.
-
Jul 20th, 2005, 11:08 PM
#3
Thread Starter
Frenzied Member
Re: Location() property
I'm trying to create a rectangle object by using the coordinates of a datagrid. I'm trying to do a screen capture. I've explored other articles and such and just simply want to grab the contents of a datagrid. The height will vary but the width should stay the same every time.
-
Jul 21st, 2005, 02:33 AM
#4
Re: Location() property
That's an odd requirement. 
If you want the datagrid's contents, use the dataset's writeXML method. It will give you the contents of the dataset (which is what is in the datagrid anyways) into an XML file.
If you're talking in terms of the GUI, as in, you want to take a screenshot of your ASP page with the grid on it, then, you cannot. You'd have to use something like an ActiveX control.
-
Jul 22nd, 2005, 09:18 AM
#5
Thread Starter
Frenzied Member
Re: Location() property
It IS and odd requirement...here is the whole story...I test a reef tank's water qualility on a regular basis. I plug those readings in a database. I wanted to be able to press a button and create a datagrid (like the shot above), then capture it, create a .jpg file, name it, ftp it to a server and over-write the file that is already there. This image is the 'signature' for me in a forum I am a member of that deals with reef tanks..This way, at any given time, others can see the quality of my water.
great idea but hard and probably not worth the trouble...the way i do it now is create the grid, then use PrintKey (a freeware program) to grab what I want off screen, save it, ftp it....I't all about a 30 second process but since I'm a developer, I thought I should use my skills LOL
-
Jul 22nd, 2005, 09:19 AM
#6
Thread Starter
Frenzied Member
Re: Location() property
oops..correction...the image isn't 'above' in this post, i posted a similar question in the vb.net forum.
-
Jul 22nd, 2005, 09:49 AM
#7
Re: Location() property
Well in answer to your original question, the location is in the controls style property.
As for why you want it, do you really need a screen shot? Why not just have the server stick the data in an excel sheet or something.
TPM
Add yourself to the VBForums Frappr Map!!
-
Jul 23rd, 2005, 07:17 AM
#8
Thread Starter
Frenzied Member
Re: Location() property
 Originally Posted by -TPM-
Well in answer to your original question, the location is in the controls style property.
As for why you want it, do you really need a screen shot? Why not just have the server stick the data in an excel sheet or something.
Because I'm not doing anything with the data...I'm using the grid as a signature to display latest conditions.
-
Jul 24th, 2005, 06:43 AM
#9
Re: Location() property
Ah I see... then it might be possible. You can generate images in ASP.NET dynamically, and I believe that's what you need to start with.
Read these:
http://www.sitepoint.com/article/gen...net-images-fly
http://msdn.microsoft.com/msdnmag/is...4/CuttingEdge/
HTH
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|