|
Glad to hear that my solution helped. Is there a button for you to click to indicate acceptance of solution? I must admit I am still quite new in this neighbourhood.
|
|
|
|
|
Welcome to code project Peter! I love this site. The only indicator I know is to type solved in place of Re:.
|
|
|
|
|
I found it. It says:
"If your problem was answered then edit your message and add "[Solved]" to the subject line of the original post, and cast an approval vote to the one or several answers that really helped you.".
Hover over the answer that you want to vote, an up arrow (upvote) and a down arrow (downvote) symbols appear for voting.
modified 29-Dec-13 20:46pm.
|
|
|
|
|
hello
i want to get LatLng (in google map) based on the textbox value.
what do i do?
i have an error when run this cod:
the error is:
Microsoft JScript runtime error: Object required
<script type="text/javascript" src="http://maps.googleapis.com/maps/api/js?key=AIzaSyDY0kkJiTPVd2U7aTOAwhc9ySH6oHxOIYM&sensor=false">
</script>
<script type="text/javascript">
var a=parseInt(document.getElementById("Text1").value);
var b=parseInt(document.getElementById("Text2").value);
var myCenter=new google.maps.LatLng(a,b);
function initialize()
{
var mapProp = {
center:myCenter,
zoom:15,
mapTypeId:google.maps.MapTypeId.ROADMAP
};
var map=new google.maps.Map(document.getElementById("googleMap")
,mapProp);
var marker=new google.maps.Marker({
position:myCenter,
animation:google.maps.Animation.BOUNCE
});
marker.setMap(map);
}
google.maps.event.addDomListener(window, 'load', initialize);
</script>
<input id="Text1" type="text" value="36"/>
<input id="Text2" type="text" value="59"/>
<div id="googleMap" style="width:800px;height:500px;"></div>
modified 28-Dec-13 7:57am.
|
|
|
|
|
There are a few mistakes,
1. myCenter is not initialized
2. LatLng should be float type not integer type
3. there should be a function that is activated by say a button click in order to capture the new a and b values upon changes by the user
4. a and b have to be converted to latlng type
5. Spot the rest yourself from my demo code below:
<!DOCTYPE html>
<html>
<head>
<script src="https://maps.googleapis.com/maps/api/js?v=3.exp&sensor=false">
</script>
<script>
var a;
var b;
var map;
var myCenter=new google.maps.LatLng(a,b);
function initialize()
{
a=parseFloat(document.getElementById("Text1").value);
b=parseFloat(document.getElementById("Text2").value);
var myCenter= new google.maps.LatLng(a, b);
var mapProp = {
center:myCenter,
zoom:8,
mapTypeId:google.maps.MapTypeId.ROADMAP
};
map=new google.maps.Map(document.getElementById("googleMap")
,mapProp);
var marker=new google.maps.Marker({
position:myCenter,
animation:google.maps.Animation.BOUNCE
});
marker.setMap(map);
}
function updateLocation(){
a=parseFloat(document.getElementById("Text1").value);
b=parseFloat(document.getElementById("Text2").value);
var latLng = new google.maps.LatLng(a, b); //create a latlng
map.panTo(latLng); //Make map global
}
google.maps.event.addDomListener(window, 'load', initialize);
</script>
</head>
<body>
<input id="Text1" type="text" value="1.3520830"/>
<input id="Text2" type="text" value="103.819836"/>
<button onclick="updateLocation()">Update Location</button>
<div id="googleMap" style="width:800px;height:500px;"></div>
</body>
</html>
|
|
|
|
|
thank you very much
I say condolence for the suffering of martyrdom the prophet Mohammad and the Imam Hasan and the Imam Reza to all of the Muslims.
modified 1-Jan-14 11:24am.
|
|
|
|
|
Hello friends, how was the day? Someone should give me idea about this. There is this amazing look in code project that I like so much. Which is, when a cursor is hover over Discussion, dropdown menus will display where you can click other options and you will be redirected to the specified url. Please someone should kindly give me the clue to do this!!! Thanks to all.
|
|
|
|
|
Hi,You can get this look by using CSS Menu.you can create it by own or else you can download it from sites.
Have a look at this Page[^].
To learn all there is to know. I know I'll be disappointed one day, but I've made a good start, and the eventual disappointment is likely to be brief.
-Roger Wright
Never doubt that a small group of thoughtful, committed people can change the world. Indeed, it is the only thing that ever has.-Margaret Mead
|
|
|
|
|
there any projects like web cam chat between 2 systems ?,
i need immediate replay for this question
for my final year projetc
|
|
|
|
|
There may well be lots of similar projects, and no doubt Google will be able to find them for you.
Veni, vidi, abiit domum
|
|
|
|
|
i want to access the last modified time of the blob. plz help thanx in advance
|
|
|
|
|
Need more info.
There are only 10 types of people in the world, those who understand binary and those who don't.
|
|
|
|
|
Hello friends, I have a problem with my asp.net website under design. When visitors login, I stored their login email and password in a session i.e Session("email")=dr("email"), Session("password")=dr("password"). So that they can access their info in the home page with the session values. The concept here is that, when users login, on page load of the home page, it should display the person info on the page using the session values to query the database. It works perfectly, but, the problem is that when it get to sometime, and the page is refresh or a button is clicked, the following error occurred. Parameterized query email, password' expect parameters value @email, @password which was not supplied. I tried to modify the sessionstate as follows<sessionstate timeout="60"> but the error still occurs. What is really wrong here? If there is any other way I can store the login info without session, please tell me. I really need help. Thanks!
|
|
|
|
|
How To Change ASP.NET Session Timeout[^]
From above link: Why increasing of session timeout maybe not works
In some cases, when you increase session timeout, then run web application, session will still expire. There could be few possible reasons for this.
Notice that session timeout should be less than Application pool idle timeout, so if you increase session timeout, you have to increase application idle timeout too. Otherwise, application will get recycled. If application is recycled, sessions will expire automatically.
Also check this too
Troubleshooting Expired ASP.NET Session State and Your Options[^]
thatrajaCode converters | Education Needed
No thanks, I am all stocked up. - Luc Pattyn
When you're wrestling a gorilla, you don't stop when you're tired, you stop when the gorilla is - Henry Minute
|
|
|
|
|
Ooooooh, how can I thank you thatraja? You have solved the real task for me. Thanks alot, I really appreciate.
|
|
|
|
|
Otekpo Emmanuel wrote: Ooooooh, how can I thank you thatraja? Please Santa...[^]
thatrajaCode converters | Education Needed
No thanks, I am all stocked up. - Luc Pattyn
When you're wrestling a gorilla, you don't stop when you're tired, you stop when the gorilla is - Henry Minute
|
|
|
|
|
Hello friends, please I need your help in this stuff. I have a datalist control on my asp.net webpage with the following buttons(Add, Remove, Cancel). I'm able to code the the button add using OnItemCommand. But, I'm unable to code the one of Remove and Cancel to call the sub procedures I wrote in vb code behind. Also, I would like a specific record to be removed from the datalist control when the remove button is click. Please help. Thanks in advance!
|
|
|
|
|
I here mention a complete code below in Data List Add,Remove and Update.
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data.SqlClient;
using System.Data;
public partial class mytesting : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
GetData();
}
}
private void GetData()
{
SqlConnection con = new SqlConnection("Data Source=.;Initial Catalog=jogi;Integrated Security=True");
try
{
con.Open();
SqlCommand cmd = new SqlCommand("select * from jogi2", con);
SqlDataAdapter da = new SqlDataAdapter(cmd);
DataSet ds = new DataSet();
da.Fill(ds);
DataList1.DataSource = ds.Tables[0];
DataList1.DataBind();
}
finally
{
con.Close();
}
}
protected void DataList1_EditCommand(object source, DataListCommandEventArgs e)
{
DataList1.EditItemIndex = e.Item.ItemIndex;
GetData();
}
protected void DataList1_CancelCommand(object source, DataListCommandEventArgs e)
{
DataList1.EditItemIndex = -1;
GetData();
}
protected void DataList1_UpdateCommand(object source, DataListCommandEventArgs e)
{
String id = ((Label)e.Item.FindControl("Label3")).Text;
TextBox role = (TextBox)e.Item.FindControl("TextBox1");
TextBox password = (TextBox)e.Item.FindControl("TextBox3");
SqlConnection con = new SqlConnection("Data Source=.;Initial Catalog=jogi;Integrated Security=True");
con.Open();
SqlCommand cmd = new SqlCommand("update jogi2 set role='" + role.Text + "',password='" + password.Text + "'where id ='" + id + "'", con);
int i = cmd.ExecuteNonQuery();
if (i > 0)
{
Label4.Text = "Recard Updated successfully....";
GetData();
}
}
protected void DataList1_DeleteCommand(object source, DataListCommandEventArgs e)
{
String id = ((Label)e.Item.FindControl("Label1")).Text;
SqlConnection con = new SqlConnection("Data Source=.;Initial Catalog=jogi;Integrated Security=True");
con.Open();
SqlCommand cmd = new SqlCommand("delete from jogi2 where id='" + id + "'", con);
int i = cmd.ExecuteNonQuery();
if (i > 0)
{
Label4.Text = "Recard Deleted successfully....";
GetData();
}
}
protected void DataList1_ItemCommand(object source, DataListCommandEventArgs e)
{
if (e.CommandName.Equals("Insert"))
{
SqlConnection con = new SqlConnection("Data Source=.;Initial Catalog=jogi;Integrated Security=True");
con.Open();
TextBox role = (TextBox)e.Item.FindControl("TextBox4");
TextBox password = (TextBox)e.Item.FindControl("TextBox5");
SqlCommand cmd = new SqlCommand("insert into jogi2 values('" + role.Text + "','" + password.Text + "')", con);
int i = cmd.ExecuteNonQuery();
if (i > 0)
{
Label4.Text = "Recard inserted successfully....";
GetData();
}
}
}
protected void LinkButton5_Click(object sender, EventArgs e)
{
Response.Redirect("default2.aspx");
}
}
For any problem you are faced hit to reply..
happy coding :)
jsb
|
|
|
|
|
Waooo, what a marvellous post! Banger, thank you very much. You post was easy to understand. Thanks alot...
|
|
|
|
|
i am not able to connect to remote server with filezilla that is shared hosting its giving me connection timed out error while i try to connect to remote server using their IP
|
|
|
|
|
What's your question?
There are only 10 types of people in the world, those who understand binary and those who don't.
|
|
|
|
|
Hi Everybody,
I have PC with win server on it, i would like to host my site there
and access it from other computer on my network (WLAN) before i pay for hosting.
Can you help me do it?
|
|
|
|
|
|
put it in IIS,you can user IP view the web,like 192.168.1.123:801/default.aspx
|
|
|
|
|
if the host computer is server OS,you can setting DNS,if the host computer ip is 192.168.1.101,you can put it int DNS and setting ip with domain,like www.a.com but just access in WLAN
|
|
|
|
|