|
Hi,
I want to uploading a image and retrive, i uploaded but in database its storing like binary data, so iam not getting my image in output. Iam using mssql.
Can u pls help me
krishna
krishna
|
|
|
|
|
OK, you have a few problems here
1 - binary data is how you want to store it, you just need to turn that data back into an image, which you do by putting it into a memory stream and building an Image out of that.
2 - because you're using ASP.NET, any images you store in the database can only be served inside a page if you feed them out through a HTTPhandler. A far easier approach is to store the images in your file system and store the path to them in SQL Server.
Christian Graus - Microsoft MVP - C++
"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 )
|
|
|
|
|
Hi,
I have ASP.NET application in which i am showing some reports in pdf format. Application is login based some have rigths to see the report while some don't. Problem is whenever someone opens reports they are getting stored in Client Temporary folder. Any solution. I cannot change client setting.
I have asked another question in ADO.NET forum, if anyone can give answer to that one too. Here is the link
http://www.codeproject.com/script/comments/forums.asp?forumid=1725&noise=1&mpp=50&select=2319646#xx2319646xx[^] Last modified: 60mins after originally posted --
Regards
Shajeel
|
|
|
|
|
I want to call my web application logout page on window close.what code should I write in javascript.
|
|
|
|
|
You can't, the window is going to close before the redirect occurs. The only way to get a message to the server when the window closes is to use AJAX.
Christian Graus - Microsoft MVP - C++
"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 )
|
|
|
|
|
in body tag add the onbeforeunload function
funciton abc()<br />
{<br />
if(confirm('navigate to logout'))<br />
{<br />
location.href('logout.aspx');<br />
return false;<br />
}<br />
<br />
}
Hope this will help u.
-- modified at 3:52 Thursday 15th November, 2007
Soniagupta1@yahoo.co.in
Yahoo Messenger Id = soniagupta1
|
|
|
|
|
Iam want to store image in mssql db, i stored its storing like <binary data="">
can u give solution for this
krishna
|
|
|
|
|
storing like Binary data
krishna
|
|
|
|
|
Funny enough, the first google hit for 'SQL Server Image' is an artice on this site.
http://www.codeproject.com/useritems/imaging.asp[^]
Christian Graus - Microsoft MVP - C++
"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 )
|
|
|
|
|
Can u pls give the code in mssql....
krishna
|
|
|
|
|
krishnavaradharajan wrote: mssql....
MSSQL ? It stores the image as byte format. Choose image datatype.
|
|
|
|
|
Yes i have given image as a data type....your previous code in oracle as asked u to give in sql.
krishna
|
|
|
|
|
It shouldn't actually matter. And Oracle uses SQL. I think you mean SQL SERver, which is T-SQL.
Christian Graus - Microsoft MVP - C++
"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 )
|
|
|
|
|
I have a requirement: If i click on a datagrid(cell),the data's corresponding to that particular data grid has to be displayed in a text box('s). I mean, if i click a roll number, corresponding data's like marks, class etc has to be displayed in a text box. Please suggest me a solution ASAP.
|
|
|
|
|
You need to insert javascript so that the data is in a div, and it's click event calls code that transfers it's value into the textbox.
Christian Graus - Microsoft MVP - C++
"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 )
|
|
|
|
|
datagrid have the propery e.item(0).text=textbox1.text write it hope it works
|
|
|
|
|
Dear Friends,
I have facing a problem in which i want data in delimited format
For Example,
Database: Northwind
Table: Products
Data Input:
ProductID CategoryID
1 1
1 2
1 3
Output:
ProductID CategoryID
1 1,2,3
i want this data in my View, can it possible please guide me.
Thanks in Advanced.
Sasmi
|
|
|
|
|
|
Hi,
U can use this Store procedure to get your goal..
SET ANSI_WARNINGS OFF<br />
Declare @ono varchar(50)<br />
DECLARE My_Cursor CURSOR FOR<br />
SELECT distinct ProductID<br />
FROM Products<br />
<br />
drop table tmp<br />
create table tmp(ono varchar(50),allname varchar(50))<br />
<br />
OPEN My_Cursor<br />
<br />
FETCH NEXT FROM My_Cursor into @ono<br />
WHILE @@FETCH_STATUS = 0<br />
BEGIN<br />
DECLARE @MyList varchar(100)<br />
set @MyList = null<br />
SELECT @MyList = COALESCE(@MyList + ', ', '') + <br />
CAST(CategoryID AS varchar(5))<br />
FROM Products where ProductID = @ono<br />
insert into tmp(ono,allname) values(@ono,@MyList)<br />
FETCH NEXT FROM My_Cursor into @ono<br />
END<br />
<br />
CLOSE My_Cursor<br />
DEALLOCATE My_Cursor<br />
<br />
select * from tmp<br />
<br />
Thanks,
Sun Rays
|
|
|
|
|
hi friends
i upload the image
by default i wrote the stored procedure,the image does not store the original name in database..it store LGO1,LGO2 like this.
my problem is i upload the file .i got image name like this ballLGO1.gif,imageLGO2.gif...
how i remove ball in ballLGO1.gif
regards
saravanan
Known Is Drop.Unknown Is Ocean
|
|
|
|
|
Well, it sounds like your code to remove the old filename is broken. You can remove it with string mashing, but you'd do better to fix the initial code.
Christian Graus - Microsoft MVP - C++
"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 )
|
|
|
|
|
hi !
I have one datalist control and there is itemtemplete of textbox. there is one check box on the form , when i click that checkbox that time all the textbox should be disable by javascript
|
|
|
|
|
use document.getElementById to find the textbox, then set it's disabled property to true.
Christian Graus - Microsoft MVP - C++
"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 )
|
|
|
|
|
thanx for sugestion but textbox is in datalist itemtemplet so how can i that texbox id ?
|
|
|
|
|
You'll have to handle the row data bound event, and get the Id and store it somewhere.
Christian Graus - Microsoft MVP - C++
"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 )
|
|
|
|