|
|
Sure.
How To: Creating Thumbnail Images
<br />
System.Drawing.Image image = System.Drawing.Image.FromFile(Server.MapPath(file));<br />
<br />
System.Drawing.Image thumbnailImage = image.GetThumbnailImage(64, 64, new System.Drawing.Image.GetThumbnailImageAbort(ThumbnailCallback), IntPtr.Zero);<br />
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
If you want to thank me for my help, please vote my message by clicking one of numbers beside "Rate this message". Why vote? Plz Read it here. Thank you.
|
|
|
|
|
Hi Friends,
i m using FileUpload Control in my page
now i want, user not able to upload .exe file
for that i need to specify filter fo extensions
how do i Filter extensions???
thanks
Amit Metkar
3i-infotech, Mumbai.
|
|
|
|
|
No. AFAIK, it's not possible to do that with File Upload control. maybe. you may look around flash or ActiveX control.. I'm sure that HTML file control doesn't have that feature. So, you will have to check the extension at code-behind.
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
If you want to thank me for my help, please vote my message by clicking one of numbers beside "Rate this message". Why vote? Plz Read it here. Thank you.
|
|
|
|
|
Amit.Amit.Amit..... wrote: now i want, user not able to upload .exe file
for that i need to specify filter fo extensions
Specifying filter is not possible in file upload control. But you can check the file extension like this and alert user regarding that
if (File1.PostedFile.FileName.EndsWith(".exe"))
{
}
else
|
|
|
|
|
Use javascript for the validations since u cant filter the HtmlInputFile control.
Ask if u want the code u have 2 do it in the onchange method.
|
|
|
|
|
Use javascript for the validations since u cant filter the HtmlInputFile control.
Ask if u want the code. u have 2 do it in the onchange method.
|
|
|
|
|
you should use this code:
private bool IsAccept(string fileName)
{
bool ok = false;
string ext = System.IO.Path.GetExtension(fileName);
if (ext == ".jpe" || ext == ".jpeg" || ext == ".pjpeg" || ext == ".gif"
|| ext == ".jpg" || ext == ".bmp" || ext == ".png" || ext == ".x-png")
{
ok = true;
}
return ok;
}
Hope that help you!
vtkiet05
|
|
|
|
|
javascript cannot interact with the input control, or the file system, AFAIK.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
I guess the code vtkiet05 shows us is Server-side code. not Javascript. I believe that that code is not interacting with File System. It's just trying to get the extension of file by using System.IO.
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
If you want to thank me for my help, please vote my message by clicking one of numbers beside "Rate this message". Why vote? Plz Read it here. Thank you.
|
|
|
|
|
|
hi Guys
Is there any live application to search for code, we have lots n lots of sites to get the source codes, why cant we make a web application with a good search engine to search pure text source code, anything related to code.
For eg. store procedure's, HTML, ASP codes, technical text, code-behind, javascript, java codes,
only pure text should be stored, its should be a very simple application with no links, only to maintain and retrieve, there will be no data editing for the users.
uploading of files are not allowed since many technical websites are providing this feature,
The plan
Here the users can store information taken from the internet(pure text) when he/she visits for reference, later he/she need not come to this same link to take the specific code, instead he/she can search the code in this new Code Manager portal,
the user will have to provide the description of code or technical text and each source code should be allocated under different sets,
for eg. if its HTML code, the language should be set as HTML for this source code
How the search works
A search with different criteria should be given..
based on desciption
based on language
based on date stroed
based on unique words,
base on tags
we should make this application very simple to handle
winnie
|
|
|
|
|
I don't think we need that. We already have Google. I don't even use Google Code Search. Web Search and Blog search are good enough...
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
If you want to thank me for my help, please vote my message by clicking one of numbers beside "Rate this message". Why vote? Plz Read it here. Thank you.
|
|
|
|
|
even i understand that.. since Google is the mother of all searches ,
but here in code manager it be will used as a follow up, coz the user who's going to search for a code can be very sure that code will exists coz this portal will be used by coders,, there will no other link to browse around. its like having a reference just like a what a LIBRARY does
regards
winnie
|
|
|
|
|
codelinks wrote: Here the users can store information taken from the internet(pure text) when he/she visits for reference, later he/she need not come to this same link to take the specific code, instead he/she can search the code in this new Code Manager portal,
Violation of copyright laws.
Moreover your question has nothing related with ASP.NET. Better forum would be Lounge.
|
|
|
|
|
Spamming the whole site won't win you any friends.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Hi codelink,
Don't say like that here. dude.
"Christian" is the one who is always helping to solve other people's problems here.
From our point of view, the way you are doing is not good.
Be careful. friend. Enjoy!
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
If you want to thank me for my help, please vote my message by clicking one of numbers beside "Rate this message". Why vote? Plz Read it here. Thank you.
|
|
|
|
|
hi Michael
i know christian is a very good professional, he has contributed in code project a lot..his work in code project shows it all.... you cant compane christian with any one around here.. but i posted a question which would benefit all of us,,
im sorry if i hurt any one in this group......
regards
winnie
|
|
|
|
|
Thanks for understanding. my friend.
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
If you want to thank me for my help, please vote my message by clicking one of numbers beside "Rate this message". Why vote? Plz Read it here. Thank you.
|
|
|
|
|
I have made a user control where I have used menu control.When I am using the site on my computer it is running fine with Mozilla 2.0 and IE 6.0 but when I am running it on different computer, all the menu item's location get disturbed.
Anybody have any idea what is the problem?
I am using .NET 2.0 and IE 6.0
|
|
|
|
|
bhavna816 wrote: when I am running it on different computer, all the menu item's location get disturbed.
The same verion of browsers installed in different computer?
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
If you want to thank me for my help, please vote my message by clicking one of numbers beside "Rate this message". Why vote? Plz Read it here. Thank you.
|
|
|
|
|
yes! the same version of IE is installed on both the computers i.e. IE 6.0
|
|
|
|
|
|
S A R I T H wrote: how can i impliment Thread in treeview.
Thread in TreeView?
Why do you need to do like that? maybe. Ajax might be the solution for you..
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
If you want to thank me for my help, please vote my message by clicking one of numbers beside "Rate this message". Why vote? Plz Read it here. Thank you.
|
|
|
|
|
i hav to print numbers like this
1,proc 1
11,proc2
2,
12,
3,
13,
4,
14,
5,
15
could u pls help me
Sarith...
If you want to thank me for my help, please vote my message by clicking one of numbers beside "Rate this message". Why vote? Plz Read it here. Thank you
|
|
|
|