|
Its been a year that i have used .NET for development, and now am back to it again.
Now, the problem is that I need to work on an application developed on the .NET 2.0 framework, and am wondering which MS IDE to use with it
should i use:
- Visual Studio 2005
- Visual Studio .NET Professional
- Visual Studio .NET 2003
- Visual Studio 2008
I dont have the MSDN subscription for VS .NET 2005
HELP!
------------------------------------
Vision is the ability to see the invisible
|
|
|
|
|
Use VS 2008.
You can target development on any framwork.
I didn't get any requirements for the signature
|
|
|
|
|
ToddHileHoffer wrote: You can target development on any framwork.
Not quite, with VS 2008 you can target from 2.0 upwards.
|
|
|
|
|
Hi
I have a screen that needs to limit the comments field to 450 charaters. I have set the Maxlength to 450 but it still allows the user to carry on typing. I have also tried using a javascript function but it is causing a server script error on this screen.
The record is then submitted and sent via workflow to an approver but when the approver wants to approve it an error message appears saying that the string has been truncated and the statement terminated. Any idea on how to prevent this error?
How do I limit the input?
J9
|
|
|
|
|
are you using textmode:multiline as it doesn't work for this
you could try a custom validator for the textbox and set the limit to 450
|
|
|
|
|
if the textbox is muilti rows, the maxlenth is invalid..
so you can use the javascript ...
can you show the javascript error on your screen?
Study...
|
|
|
|
|
I'm trying to get all hostnames for a server. Let me explain from the beginning. I'm creating a website about the countries of the world that will run on a web farm. We have a subdomain for each country e.g. us, uk, australia .. etc .. we're going to assign those subdomains to different servers in the farm, for example, one server can have those domain names, us.oursite.com, uk.oursite.com, australia.oursite.com, newzealand.oursite.com .. another server could have those subdomains norway.oursite.com, sweden.oursite.com, finland.oursite.com .. etc. Now basically what I'm trying to do is that, I want the servers to able to detect their own subdomains at startup. In the previous example, the server that has the us.oursite.com, uk.oursite.com, australia.oursite.com, newzealand.oursite.com domain names, should be able to get those names at startup (in application.start()), how sould this be possible?
Any suggestions are very much appreciated...
|
|
|
|
|
Hello all,
I am a newbie to the AJAX programming techniques. I want to update my database as per choice made by the user and inform him/her about the same if the updation has been done successfully. The platform is ASP.NET
Following is my implementation:
The file containing following two javascript functions has been included in my ASPX file.
This function (i.e. submitValue) is called on the button click and the parameter (i.e. value) is the data I want to update on my database. The function "getXmlHttp()" in bold is returning the required XMLHttpRequest object by using the suitable method as per the browser detected. As I want to inform the user on the same page so the variable "requestURL" passed in the open() function contains the URL of the same page with updated querystring.
function submitValue(value)
{
try
{
//Create the XMLHttpRequest object.
xmlHttp = getXmlHttp();
//Call the function to process the response from the server
xmlHttp.onreadystatechange = stateChanged;
//Send request to the server
var requestURL = location.href+"&q="+value;
xmlHttp.open('GET',requestURL,true);
xmlHttp.send(null);
}
catch(e)
{
alert("Error : Sending request");
}
}
Following javascript function which is called above is used to process the server response.
function stateChanged()
{
try
{
if (xmlHttp.readyState==4 ||xmlHttp.readyState=='complete')
{
var retValue;
retValue = xmlHttp.responseText;
if(retValue=="0")
document.getElementById("divRateInfo").innerHTML = "Rating submition failed. Try again.";
else
document.getElementById("divRateInfo").innerHTML = "Rating successfully submited!";
}
}
catch(e)
{
alert("Error : Processing response");
}
}
Finally following is the code behind written on the corresponding ASPX.CS file. The method is called on the page load.
private void SaveRating()
{
try
{
if (Request.QueryString["q"] != null)
{
int nUserRate = Convert.ToInt32(Request.QueryString["q"].ToString());
SqlParameter[] sqlParam = new SqlParameter[2];
sqlParam[0] = new SqlParameter("@rate", SqlDbType.Int);
sqlParam[0].Value = nUserRate;
sqlParam[1] = new SqlParameter("@id", SqlDbType.Int);
sqlParam[1].Value = Convert.ToInt32(this.Request.QueryString["id"].ToString());
object strInfo = SqlHelper.ExecuteScalar(ConfigurationSettings.AppSettings["ConnectionString"], CommandType.StoredProcedure, "sp_UpdateRating", sqlParam);
Response.Expires = -1;
Response.Write(strInfo.ToString());
}
}
catch (Exception objExcep)
{
Response.Expires = -1;
Response.Write("0");
}
}
Everything works as per expectation, even my database is getting updated perfectly but the "responseText" property in the function "stateChanged()" above is returning the code for my ASPX page instead of just 0 or 1 as expected.
O my god the post has become so long but I wanted to make myself clear. Can anyone suggest any solution? Please help!
|
|
|
|
|
Hi dear,
Ur code is perfect for xmlhttp,
may be there is some bug in the page where u r getting response.. try debug the code by direct opening the url with passed parameters u now can easily trace the bug if any..
Hello Forum
Always be in touch to help about the topic ASP.NET
|
|
|
|
|
Hai,
Any one know how to Place a Record No in Cross-Tab
Thanx
If you have an apple & I have an apple and we exchange our apples, then each of us will still have only one apple but if you have an idea & I have an idea and we exchange our ideas, then each of us will have two ideas!
|
|
|
|
|
frnds
I want to create a session on client side that is independent from server one. is it possible ? if yes then how ? plz help me out with this issue.
thanks
manish
hi
|
|
|
|
|
you might want to explain what you mean by "create a session on the client side". It is not obvious what you are trying to achieve.
|
|
|
|
|
what i want is when i request for page wich on server to client machine then sessions should maintain on client system.......means server must not hold sessions for that page as i dont want iis hold connections.
hi
|
|
|
|
|
Hi all i have a case where i need to display all textboxes in lables and i want to maintain the html tags. I have used labels but didnt work. I tried literal with mode="Encode" but also not working
Any ideas, thanks
|
|
|
|
|
Can use a label like so:
label.text = Server.HtmlEncode(textbox.text)
|
|
|
|
|
Use Mode="PassThrough" .
Experience is the sum of all the mistakes you have done.
|
|
|
|
|
I have tried this also but didnt work
here is my code if u can provide some help
<br />
<table style="width: 100%; height: 100%"><br />
<tr><br />
<td style="text-align: center"><br />
<table class="TableMain" style="width: 98%"><br />
<tr><br />
<td class="TableHeader"><br />
Address<br />
</td><br />
</tr><br />
<tr><br />
<td><br />
<asp:LinkButton ID="linkNew" runat="server" CssClass="Pagelinks"><img src='../../App_Themes/Professional/Images/Add.gif' alt='Add' border='0' />Add New Address</asp:LinkButton><br />
</td><br />
</tr><br />
<tr><br />
<td style="text-align: center"><br />
<asp:GridView ID="gvAddress" runat="server" ShowHeader="False" Width="98%" AllowPaging="True"<br />
PageSize="3" DataKeyNames="addressId"><br />
<Columns><br />
<asp:TemplateField HeaderText="Address"><br />
<ItemTemplate><br />
<table id="TABLE1" class="TableMain" style="width: 100%"><br />
<br />
<tr><br />
<td style="width: 20%"><br />
Country:<br />
</td><br />
<td><br />
<asp:Label ID="lblCountryCode" runat="server" Text='<%#Bind("country")%>'></asp:Label><br />
</td><br />
<td style="width: 20%"><br />
Town \ Caza:<br />
</td><br />
<td style="width: 30%"><br />
<asp:Label ID="lblTownCazaCode" runat="server" Text='<%#Bind("TownCaza")%>'></asp:Label><br />
</td><br />
</tr><br />
<tr><br />
<td style="width: 20%"><br />
Stay Duration (Years-Months):<br />
</td><br />
<td><br />
<asp:Label ID="lblStayDuration" runat="server" Text='<%#LoadStayDuration(Container.DataItem("stayDuration"))%>'></asp:Label><br />
</td><br />
<td style="width: 20%"><br />
</td><br />
<td style="width: 30%"><br />
</td><br />
</tr><br />
<tr><br />
<td style="width: 20%"><br />
Remark:</td><br />
<td colspan="3"><br />
<asp:Literal ID="lblRemark" Mode="Transform" runat="server" Text='<%#Bind("remark")%>'></asp:Literal><br />
</td><br />
</tr><br />
<br />
<br />
</table><br />
</ItemTemplate><br />
</asp:TemplateField><br />
</Columns><br />
<PagerSettings Mode="NumericFirstLast" /><br />
</asp:GridView><br />
</td><br />
</tr><br />
</table><br />
</td><br />
</tr><br />
</table><br />
|
|
|
|
|
Hi,
I want my application like outlook express, so that i can send mail as well as receive emails from different site.
Is it possible.
Plz help as soon as possible..
thanxx
krishna veer singh
|
|
|
|
|
Hi,
I have a string of text of random length but need to display only the first 250 characters (preferably whole words), in a label. Any remaining words would be displayed in a seperate label.
Please can someone give me advice on what i need to do or at least the methodology i need to look into.
Many Thanks!
|
|
|
|
|
hey dear it is basics of strings.
try to use substring function of string
e.g:
string strtext;
printf(strtext.substring(0,250));
this give u a result.
Hello Forum
Always be in touch to help about the topic ASP.NET
|
|
|
|
|
Thanks!
I knew it was basic, but havent used it for soo long! I was having one of those times when trying to remember just made it harder to think clearly.
Thanks for the reply!!!!
|
|
|
|
|
Use str.LastIndexOf(' ', 250) to find the space closest to the 250th character. If it finds one reasonably close to 250, use str.Substring to get the part of the string up to the space. Otherwise you just have to cut the string at 250 anyway.
Experience is the sum of all the mistakes you have done.
|
|
|
|
|
Hi
I have created a link which should call a method by passing a parameter. My method should check for registry entries.
I could not understand How can we call a method when the user clicks a link. I was thinking to do something like this:
link.NavigateUrl = method(pubId);
will this works? Could anyone give me some Ideas how can this be implemented..
Thanks in advance,
Aruna.G
|
|
|
|
|
You can use a linkbutton, which will postback to the page for you. Do you want to check registry entries on the server (possible), or on the client (not possible using this technique)?
|
|
|
|
|
Hi
Thank you very much for your reply. I dont have linkbutton , its just a hyperlink and I want to check the registries on client side.
And I coded my method like this.
public void checkRegistry(string pubId)
{
string fileExt = ".coex";
string pubIdVal = pubId + fileExt;
RegistryKey key = Registry.ClassesRoot.OpenSubKey(".coex");
if (key != null)
{
}
else
{
Label msgBox = new System.Web.UI.MobileControls.Label();
msgBox.Text = "Device does not contain the PocketPCCab1.CAB from doxtop!! " +
" Please install the CAB file and try again";
tpcPageMenu.Controls.Add(msgBox);
}
}
this method I have to call from my hyperlink.
Thanks
Aruna.G
|
|
|
|