|
Yes, I got the solution. Thanks a lot.
|
|
|
|
|
Use mailto[^]
I know the language. I've read a book. - _Madmatt
|
|
|
|
|
Thanks dude. its working now.
|
|
|
|
|
Hi Everybody,
I am using web services first time. Only for my understanding I have used very simple functionality: Addition of two numbers and population of a dropdown list. My questions are
1- when I used "Namespace" It raised an error that 'error BC30002: Type 'First Web Service' is not defined.'
later I commented out namespace it is working fine. any tip how to sortout this error.
2- Basically I play all the time with database (binding and manipulating data with controls )and desperate to use WCF and web services. Is this any better/helpful to use in the same way I have use in the FirstWebService.
why I am asking this because I can perform the same functionality using simple classes. I dont see any difference or I am confusing myself.
any help will be appreciated.
FirstWebService code:
Imports System.Web
Imports System.Web.Services
Imports System.Web.Services.Protocols
Imports Microsoft.VisualBasic
Imports System.Data
Imports System.Data.SqlClient
Imports App_Code.DB
Imports App_Code.Web
'Namespace App_Code.Web
' To allow this Web Service to be called from script, using ASP.NET AJAX, uncomment the following line.
'<System.Web.Script.Services.ScriptService()> _
<WebService(Namespace:="http://tempuri.org/")> _
<WebServiceBinding(ConformsTo:=WsiProfiles.BasicProfile1_1)> _
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
Public Class FirstWebService
Inherits System.Web.Services.WebService
Dim dbeng As DBEngine
Dim lEBStruct As EBStruct
Public Sub New()
dbeng = New DBEngine
dbeng.YourDBName = ConnectionSource.DBName.PupilVoice
End Sub
Private _YGid As Integer
Private _YGDesc As String
Public Property YGId() As Integer
Get
Return _YGid
End Get
Set(ByVal value As Integer)
_YGid = value
End Set
End Property
Public Property YGDesc() As String
Get
Return _YGDesc
End Get
Set(ByVal value As String)
_YGDesc = value
End Set
End Property
<WebMethod()> _
Public Function HelloWorld() As String
Return "Hello Mathematician"
End Function
<WebMethod()> _
Public Function AddTwoIntegers(ByVal dig1 As Integer, ByVal dig2 As Integer) As String
Return Convert.ToString("<br/>you entered teri tou two digits: " & dig1 & " and " & dig2 & ". Sum of two digits is " & dig1 + dig2)
End Function
<WebMethod()> _
Public Function YearGroup_GetAll() As EBStruct
Dim lcmd As New SqlCommand
Dim dbeng1 As New DBEngine
lcmd.CommandType = CommandType.StoredProcedure
lcmd.CommandText = "YearGroup_GetAll"
lEBStruct = dbeng.GetDataTable(lcmd)
Return lEBStruct
End Function
End Class
'End Namespace
|
|
|
|
|
I want to know the direct API's for paypal intigration in my asp.net application. Please help me ?
Thanks for your reply
Regards
Ratnesh Nirmal Bharos
( Web Developer Asp.net, C#)
|
|
|
|
|
|
|
HI,
I have develped one small application in asp.net with ajax..
How to deploy web application in FTP Server..
locally perfactly working.But Remote server only problem..
And also im facing one problem..Is it possible to Having morethan one web config file in FTP????
Yours,
KaNNaN
-----------------------------------------------------------------
"Success is When Ur Signature Becomes An Autograph"
|
|
|
|
|
I am new to MVC i have a very basic question. Hope you will bear it.
I have two tables Contact and Addresses. Addresses is the child table of Contact. When i create view for Contact. i also want to get addresses for user as many as user wants. For contact table i bind the textbox and add validation like this
<%= Html.TextBoxFor(model => model.ContactName) %>
<%= Html.ValidationMessageFor(model => model.ContactName) %>
Now my question is that how can i bind address field on create view screen.
Regards Tassadaque
|
|
|
|
|
Hi all,
I have got a problem in my application.I am executing a query which is quite lengthy.Some times i got a problem page time out expire.Can any one help me how to overcome this problem.
i have used
command.Timeout and connectTimeout and pooling in connection string.
But still it is not working.
|
|
|
|
|
I m not sure it will help but,
try to increase execution time of your page
like
<httpRuntime
executionTimeout="3600"
/>
hope this help
|
|
|
|
|
|
I get an javascript expected ')' error on the code below:
function toggle()
{
if (document.getElementById("<%= RadioButtonList_Liability.ClientID %>").value == "Yes")
{
document.getElementById("<%= Label_Liability.ClientID %>").style.visibility = "inherit";
}
else
{
document.getElementById("<= Label_Liability.ClientID %>).style.visibility = "hidden";
}
)
for the life of me, I don't see anything wrong ....
|
|
|
|
|
Never mind, now that I see it in this editor I see the paren is wrong ... sigh ...
|
|
|
|
|
line no 10 in your javascript....
document.getElementById("<= Label_Liability.ClientID %>).style.visibility = "hidden";
% is missing......
!- F - R - I - E - N - D - S -!
|
|
|
|
|
Couple of things that I see is missing/wrong...
1.
document.getElementById("<= Label_Liability.ClientID %>).style.visibility = "hidden";
should be
document.getElementById("<%= Label_Liability.ClientID %>").style.visibility = "hidden";
2. I see one extra ")" at the end of the javascript block... Line 12.
Suggestion -
Always use single quote ['] with javascript.
|
|
|
|
|
Salam
I've problem to add a picture to database sqlserver,what's the simple solution to this and how can i use the table which it has pictures with formview and this is the example that's i mist have,and thanks to ALL.
SALAM.
|
|
|
|
|
|
Hi,
I am working with the HTTP Post method to log the user into my framework. I have done everything required for it, but when I run the page it does not redirect to the Page given in URL. What I am doing wrong?
Thanks
|
|
|
|
|
friend you need to give more information for solving your problem.
|
|
|
|
|
Without seeing your code it is not possible to say where you are wrong. Add the relevant code snippet to your question.
..Go Green..
|
|
|
|
|
Here is my code:
string strResponse;
string strPost;
protected void Page_Load(object sender, EventArgs e)
{
strPost = "txtUserName=abc&txtPassword=123";
UTF8Encoding objUTFEncode = new UTF8Encoding();
byte[] arrRequest = null;
Stream objStreamReq;
StreamReader objStreamRes;
HttpWebRequest objHttpRequest;
HttpWebResponse objHttpResponse;
Uri objUri = new Uri("http://www.mysite.com");
objHttpRequest = HttpWebRequest.Create(objUri) as HttpWebRequest;
objHttpRequest.KeepAlive = false;
objHttpRequest.Method = "POST";
objHttpRequest.ContentType = "application/x-www-form-urlencoded";
arrRequest = objUTFEncode.GetBytes(strPost);
objHttpRequest.ContentLength = arrRequest.Length;
objStreamReq = objHttpRequest.GetRequestStream();
objStreamReq.Write(arrRequest, 0, arrRequest.Length);
objStreamReq.Close();
CookieContainer cookieContainer = new CookieContainer();
objHttpRequest.CookieContainer = cookieContainer;
//Get response
objHttpResponse = objHttpRequest.GetResponse() as HttpWebResponse;
objStreamRes = new StreamReader(objHttpResponse.GetResponseStream(), Encoding.ASCII);
strResponse = objStreamRes.ReadToEnd();
objStreamRes.Close();
}
|
|
|
|
|
Hi, I have a datalist paging enabled in my datalist that shows 10 records per page. but I would like to display a image after every 3rd record. not sure how do i do that. could someone please help? I basically like to inject a hard coded image in the datalist.
|
|
|
|
|
This is Silverlight client-side code.
I would expect it to simultaneously increment the values of both textboxes and therefore take approx. 10 seconds to complete.
Instead, it takes 20 seconds as if the two cycles were running sequentially.
I know there's something wrong with it, but what?
private void button1_Click(object sender, RoutedEventArgs e)<br />
{ <br />
BackgroundWorker bw = new BackgroundWorker(); <br />
bw.RunWorkerCompleted += new RunWorkerCompletedEventHandler(Rsz);<br />
bw.RunWorkerAsync();<br />
textBox1.Text = "0";<br />
for (int i = 0; i < 100; i++)<br />
{<br />
System.Threading.Thread.Sleep(100);<br />
textBox1.Text = i.ToString();<br />
}<br />
}<br />
private void Rsz(object sender, RunWorkerCompletedEventArgs e)<br />
{<br />
textBox2.Text = "0";<br />
for (int i = 0; i < 100; i++)<br />
{<br />
System.Threading.Thread.Sleep(100);<br />
textBox2.Text = i.ToString();<br />
} <br />
}
|
|
|
|
|
I have an asp hidden field on my webpage and am trying to access it through javascript. see code below:
function filterclick(){
alert('hello');
alert(document.getElementById('FilterSelected').value);
alert('hello');
<asp:heddenfield id="FilterSelected" runat="server" value="0">
Now, I see the first alert('hello') but none after that?
Thanks,
Steve Holdorf
|
|
|
|