|
I would suggest doing something like using Javascript to obtain the client width of the browser, then resizing the image accordingly based on this. For example, you could make the image width 50% of the browser client width, then using this, you could change the image height to make it in proportion with the width.
I can give you a code example if you want it.
Hope this helps,
--Perspx
"The Blue Screen of Death, also known as The Blue Screen of Doom, the "Blue Screen of Fun", "Phatul Exception: The WRECKening" and "Windows Vista", is a multi award-winning game first developed in 1995 by Microsoft" - Uncyclopedia
|
|
|
|
|
Hi, i am making a webpage with asp and C# and now I have a couple of buttons with a table below. Now when the user click a button it loads the appropriate data from sql and puts it in the table. But how can i make this happen without the page refreshing? I have put the code in the OnClick of the button but the page still refreshes(which takes a while because it also reloads the images - which is why i want to do it without refreshing). I have seen this being done on phpBB forums when you quick reply.
Please help me.
Thanks
|
|
|
|
|
Use Ajax.
There's no othr option to prevent PostBack
Anand Desai
Developer
Atharva Infotech
|
|
|
|
|
So its because its causing a postback? Are there any other controls that dont cause postback's that i can use instead?
|
|
|
|
|
Debug your code. You will find its doing "PostBack" each time.
You must use Ajax to resolve it
Anand Desai
Developer
Atharva Infotech
|
|
|
|
|
Sorry for being ignorant and wasting your time, but I have never use AJAX. Wouldnt i have to install something on the server for that? I have no access to the server except htdocs folder.
Also how would I do this with ajax? Can i run a C# method(like an onlclick function) that would do it?
Thanks
|
|
|
|
|
Ajax = Asynchronious JavaScript with XML
For your problem, no need to install AjaxToolKit, just search google like this "Load DataGrid using Ajax" or "Run SQL query using Ajax".
N u will find solution
Anand Desai
Developer
Atharva Infotech
|
|
|
|
|
Hi all ,
I am creating mail compose editor in web, but iframe is not working in mozilla and the other problem are spacing b/w lines i.e, text format (Heading, Paragraph, etc. and if i refresh the page the content is missing in IFRAME .
but i found a workaround to do that .
But the problem comes with and while selecting the <b>" text format"</b>
like Paragraph ,Header1 ,2,3,4,5,6 Address .
The sample appl for composing
<a href="http://www.mozilla.org/editor/midasdemo/">http://www.mozilla.org/editor/midasdemo/</a>[<a href="http://www.mozilla.org/editor/midasdemo/" target="_blank" title="New Window">^</a>]
if i copy the source and paste in a notepad with .html file name and
opening it with InternetExpolrer 7.0
i am getting the spacing between lines if the format option as NORMAL . it is not consider the format as normal,considering a <p>.
ANY WORKAROUND for spacing i.e.,<b> text format and content missing after refresh </b>?
Thanks </p>
|
|
|
|
|
sqldatasoruce1.selectcommand = "select * from emp";
if i want the particular result like someone emp name how to get it?
thanks.
modified on Friday, August 1, 2008 6:08 AM
|
|
|
|
|
where emp.name = "something"
or if you are comparing to string
where emp.name = '" + stringname + "'"
|
|
|
|
|
that is ok select * from emp where emp_id = 1
but now i want to print the value
how to get this value???
thanks.
|
|
|
|
|
SqlDataReader readerEmp = sqldatasoruce1.ExecuteReader();
while(readerEmp.Read())
{
int EmpID = (int)readerEmp["Emp_ID"];
//the "emp_id" is the column name in the sql database.
string EmpName = (string)readerEmp["Emp_Name"];
}
|
|
|
|
|
sorry no such thing SqlDataSource.ExecuteReader() ?????
|
|
|
|
|
ok, ur misunderstanding. Heres code from something i did a while back. just adapt it to your needs.
sqlConn.Open();
SqlCommand cmdShowCat = sqlConn.CreateCommand();
cmdShowCat.CommandText = "SELECT * From Type WHERE TypeName LIKE '[R]%'";
SqlDataReader readerShowCat = cmdShowCat.ExecuteReader();
while(readerShowCat.Read())
{
string TypeName = (string)readerShowCat["TypeName"];
catagoriesLabel.Text = catagoriesLabel.Text + " " + TypeName;
}
if (catagoriesLabel.Text == "") { catagoriesLabel.Text = "Sorry, there were no results."; }
sqlConn.Close();
|
|
|
|
|
SqlDataSource sds = new SqlDataSource();
sds.ConnectionString = ConfigurationManager.AppSettings[0];
sds.SelectCommand = "select datediff(day, date_, '7/26/2008') from date_tab ";
i want the result in my case the date difference from this query
thanks.
|
|
|
|
|
hello frndz,
I am very confused, which transaction level should i use ???
What i want to do is , I have to insert 1000 value in a database table n i used transaction handling concept for that purpose.
My Isolation level is "READ COMMITED" but if any other user try to insert record in same table then it will retun me TIME OUT exception.
i think it will lock whole table till i completed my transaction...
what can i do for it ???
can i lock that perticular rows which i inserted???
any other hint ??? that table should not get locked ???
I have Sqlserver 2000 and .NET 2.0
thanks in advance
koolprasad2003
If the message is useful for U then please Rate This message...
Be a good listener...Because Opprtunity knoughts softly...N-Joy
|
|
|
|
|
Use Stored procedure instead of single transactions..
it lockes the SQL from its process Begin...to....End.
Anand Desai
Developer
Atharva Infotech
|
|
|
|
|
iam using a iframe for my mailing application .the problem is if i write some text and press enter 3 times and in the hidden field value the inner html of the iframe is getting the space which press enter 3 time like nsbsp like this how to solve this problem
|
|
|
|
|
Hi
I am using tables to do the outline design for my webpage.
The problem is, is that there is small gaps between each tables which I want to remove so that all areas are tight to each other.
Is there a way to do this, like reduce padding on table or border?
thanks
|
|
|
|
|
For the <table> tag:
<table cellpadding="0" cellspacing="0">
Regards,
--Perspx
"The Blue Screen of Death, also known as The Blue Screen of Doom, the "Blue Screen of Fun", "Phatul Exception: The WRECKening" and "Windows Vista", is a multi award-winning game first developed in 1995 by Microsoft" - Uncyclopedia
|
|
|
|
|
|
how to connect the web cam to my application.and also how to capture the picture.after cpturing the pic it can be saved in image location .it just like preparing the id card.
|
|
|
|
|
I dont think you can do this in asp.net
|
|
|
|
|
put code to start exe in event holder
Anand Desai
Developer
Atharva Infotech
|
|
|
|
|
I have DataGrid and am loding the 2500 records suessfully but am not unable to edit and save any one ca n help
|
|
|
|