|
thanks for your help
but it coudnt help me
i want to rotate an image in image control not in a new page...(first link)
seccend is for win app:
pictureBox.Image = Utilities.RotateImage(img,(float) angle.Value );
image has not image properties
M.Alizadeh
|
|
|
|
|
AFAIK, html image control couldnt be rotated. You can define the size of the img but cant rotate.
To do this, you need to rotate the image in the server and produce another image and show it in browser. Use graphics object to draw a new image rotating it in an angle and show it in browser.
This article could be a good help for you :
Image Rotation in .NET[^]
After you rotate the image, show it using img tag.
On the other hand:
If you want to rotate in browser itself, you might use Flash / silverlight which are capable of doing this.
Hope you got this.
Cheers
|
|
|
|
|
|
I think this javascript uses moveto function to actually rotate an image.
Use this Javascript
http://www.walterzorn.com/scripts/wz_rotateimg.js
I think you can do this without Flash and Silverlight.
|
|
|
|
|
Hi, i want to read data from the source file of 3rd party website. The page is not in my control. Here i need to do two things.
a. I just read the html content of that page in to string first
b. and later i want to retrive some specific data from that string.
the first option is ok. The second option i am not getting how to retive the data.
<tr>
<th>First Name</th>
<td width="100%"><input name="p_first_name" type="text" id="f-first-name" value="JEAN" /></td>
</tr>
<tr class="tr-back">
<th class="tr-back">Last Name</th>
<td><input name="p_last_name" type="text" id="f-last-name" value="AAREN" /></td>
</tr>
<tr>
<th>Occupation</th>
<td width="100%"><input name="o_occ" type="text" id="f-occ" value="UNKNOWN" /></td>
</tr>
In the above code i want to retrive the values first name, middle name and lastname. i.e JEAN, AAREN, UNKNOWN
Can any one help me how to retrive this code once reading all this html in to string..? or any other way
|
|
|
|
|
If you are sure that the resultant string is in valid XML format, just load it to XmlDocument and use XPath to get the required values. Other option is to use regular expression and look for the text.
Best wishes,
Navaneeth
|
|
|
|
|
how to load that string in to xmldocument?
G. Satish
|
|
|
|
|
|
If you place a wrapper to all the tr's it will load easily in XMLDocument / XDocument.
Just take the table tag which wrap around all the entries.
Use XElement.Load(your html string) to get the xml loaded.
Now search the elements using Linq to XML.
Cheers...
|
|
|
|
|
Dear all
I want to make a web site as a book on asp.net but the pages are jpg images not text and i can make next >> and previous <<
which controle i can use to navigate through the images in this book
thank u for advice
Kareem Elhosseny
|
|
|
|
|
Just use client side button.
When onclick to button, make an ajax call to the server(might be a dedicated handler) and change the src or img tag.
|
|
|
|
|
thanks my brother
Kareem Elhosseny
|
|
|
|
|
Here is a code project in asp.net.
i have to insert dynamically create rows in a table name : [Pin_Generate]
The number of rows are inserted by the user and then submit and it create that number of rows in that table.
But it cannot be done when its going 2nd time in a loop...
<br />
for (i = 1; i <= Convert.ToInt32(EnterByUserTextBox.Text); i++)<br />
{<br />
getNum();<br />
<br />
scomm1.Parameters.AddWithValue("@pid_no", lblprint_id.Text);<br />
scomm1.Parameters.AddWithValue("@pserial_no", lblserial_no.Text);<br />
scomm1.Parameters.AddWithValue("@ppassword", lblpassword.Text);<br />
<br />
sconn1.Open();<br />
int x = 0;<br />
x=scomm1.ExecuteNonQuery();
sconn1.Close();<br />
<br />
<br />
if (x > 0)<br />
{<br />
<br />
lblmsg.Text = "Successfully Created";<br />
update();<br />
<br />
}<br />
else<br />
{<br />
lblmsg.Text = "Please Try Again";<br />
}<br />
<br />
<br />
}<br />
Plz help me out.... its very urgent..
|
|
|
|
|
Welcome to CodeProject! Please read the forum guidelines[^] to learn how to ask better questions. People here do voluntary help and specifying urgent in the message won't help you to get answers. It is considered as rude.
To answer your question: what error are you getting? What getNum() function is doing?
There are few problems in your code. You are adding parameters in each iteration which is not correct. If you want to insert the same value N times, you don't have to open and close the database connection each time. Open it once, call ExecuteNonQuery() N times and close the connection. Here is the code after few refactorings.
int n;
if(!int.TryParse(EnterByUserTextBox.Text, out n))
{
}
using(SqlConnection sconn1 = new SqlConnection(connectionstring))
using(SqlCommand scomm1 = sconn1.CreateCommand())
{
scomm1.Parameters.AddWithValue("@pid_no", lblprint_id.Text);
scomm1.Parameters.AddWithValue("@pserial_no", lblserial_no.Text);
scomm1.Parameters.AddWithValue("@ppassword", lblpassword.Text);
try
{
sconn1.Open();
for (i = 1; i <= n; i++)
{
scomm1.ExecuteNonQuery();
}
sconn1.Close();
lblmsg.Text = "Successfully Created";
update();
}
catch(Exception ex)
{
lblmsg.Text = "Please Try Again" + ex.ToString();
}
}
Best wishes,
Navaneeth
|
|
|
|
|
Good Answer Navaneeth...
Additionally I have also marked this as answer...
Cheers.
modified on Saturday, November 14, 2009 1:51 PM
|
|
|
|
|
Thanks friend.
Best wishes,
Navaneeth
|
|
|
|
|
hi gents,
In ASP.NET solution file is in Projects folder and project files are in Websites folder. I wanna to put both in the same folder in another location..
I have copied the files from projects folder to the websites folder and its working but when i move the files to some other location its giving error "One or more files cannot be loaded...."
Please help me to find a solution for this
Thanks in advance
Regards
Ahamed Azeem
software Programmer
|
|
|
|
|
Can you please elaborate your question.
Please don't forget to mark 'Good Answer', if you find it really a good one!
Kashif
|
|
|
|
|
Thanks a lot for your reply
I created a new website. The files are inside the visualstudio2005\projects\website1 and visualstudio2005\websites\website1
I have copied the files(.sln and .suo) in visualstudio2005\projects\website1\ to the visualstudio2005\websites\website1\ and then open the project. Its working fine.
But if i copy the website1 folder from visualstudio2005\websites\website1\ to c: drive.. i cannot open the project. It is saying one or more files cannot be loaded. If I put inside Websites folder in c drive then its working.. How can i solve this
The error showing is
One or more projects in the solution could not be loaded for the following reason(s):<br />
<br />
The project file or web has been moved, renamed or is not on your computer<br />
<br />
These projects will be labelled as unavailable in solution explorer, Expand the project node to show the reason the <br />
<br />
project could not be loaded.
Hope you understand
Thanks and Regards
Ahamed Azeem
software Programmer
|
|
|
|
|
Open the Solution(which eventually an XML file) in Notepad or any XML editor and modify with the relative path in the project section. For example :
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "MyProject", "MyProject\MyProject.vbproj", "{4A2C4FC2-3D9B-4911-B5CC-3147EC7E8D6C}"
EndProject
Modify the section in bold. .NET IDE loads the project based on the project file path mentioned in project section. For multiple projects there should be more than one project block.
|
|
|
|
|
Plz help me if any one can.
How I can get Text From TypeAhead Control.
I am using Visual Studio and developing my project in Asp.net using c#.
like i am using
String str = TypeAhead1.Text;
but always null value is returned..
Simply on postback i want to show the selected text on label1. Plz send me code.
|
|
|
|
|
|
Ok.. But i think my message is overset.
|
|
|
|
|
Despite the cross posting and reposting and everything else. Did you try Google?
I thought to see what a typeahead control is and top of the search results comes this Code Project Article. Type-Ahead suggest textbox server control with Google AJAXSLT[^]
Your answer may be there, and if it is not I am sure the author can help you out if you post against that article.
Failing that there seems to be a load of other pages about the subject acording to Google.
If you have knowledge, let others light their candles at it.
Margaret Fuller (1810 - 1850)
www.JacksonSoft.co.uk
|
|
|
|
|
Sir,
In my ASP.NET application I have the dashboard.
Number of records needs to be fetched from database into it. Hence,I want to write stored procedure which gives me these records using multiple Select statements. Is it possible to fetch it? If yes how it can be done.
Thanx
|
|
|
|