|
|
I am having difficulty launch a form submit event after adding a postbackurl attribute to an imagebutton in asp.net. See code below.
I have a Login Button with an 'onclick event'... ie. see below:
************
<asp:imagebutton id="LoginButton" runat="server" text="Log In" validationgroup="Login1" imageurl="~/images/login_up.gif" onclick="LoginButton_Click1" xmlns:asp="#unknown">
************
My Event is as follows (code behind - vb):
******************
Protected Sub LoginButton_Click1(ByVal sender As Object, ByVal e As System.Web.UI.ImageClickEventArgs)
If (Left(Me.Login1.UserName, 6).ToLower = "domain") Then
Dim LoginButton As System.Web.UI.WebControls.ImageButton
LoginButton = CType(Login1.FindControl("LoginButton"), ImageButton)
LoginButton.Attributes.Add("PostBackUrl", "http://internalusersite.anyname.com/Portal/AdminLogin.aspx")
'need an event to submit the form after adding the attribute
Else
Dim LoginButton As System.Web.UI.WebControls.ImageButton
LoginButton = CType(Login1.FindControl("LoginButton"), ImageButton)
LoginButton.Attributes.Add("PostBackUrl", "http://externalusersite.anyname.com/Portal/AdminLogin.aspx")
'need an event to submit the form after adding attribute
End If
|
|
|
|
|
Hi,
I am also facing the same problem, did you get the solution for this?
|
|
|
|
|
Hi,
I got a quick question here, I'm using .NET 2.0 here and I've just seen a tool called SOAP UI. My problem is that we're working in a project which is based on a web service that is not accessible from where we r right now (So basically we're on dry runs here ). So we're thinking about finding a solution to make a mock up of that web service over there and some how (if possible) use it in our project to carry on the development work easily. I hope some of you folks out there might be able to better guide me in this scenario. Can some buddy plz tell me if this is possible if we could have some one create a mockup of that web service there and send it to us so that we can use that mock up as if it were that web service.
Hope I got my point cleared.
Thanks in advance
|
|
|
|
|
i have 2 different folders.
Admin folder and Images folder.
Admin folder has just manage.aspx form.(Images folder not in that folder)
i want to display my pics in Admin/manage.aspx page.But my images are in
Images folder.
<eit:LightBoxHyperlink ID="lb1" runat="server" Album="Sample1" Caption="Gallery 1 Pic 1"
ThumbnailUrl='<#"~/Images/"+DropDownList1.SelectedValue+"/Thumbnail/"+DataBinder.Eval(Container.DataItem,"small") %>' Height="84px" Width="113px" style="vertical-align: middle; text-align: center" />
it searches my images under the :Admin/Images.... (so i get error message)
But images under Images/..
|
|
|
|
|
Use like this
<br />
ThumbnailUrl='<../images/AddChildWBSCode.gif>'<br />
|
|
|
|
|
But i must use databinding.
ThumbnailUrl='<%#"Images/"+DropDownList1.SelectedValue+"/Thumbnail/"+DataBinder.Eval(Container.DataItem,"small") %>'
i dont display just one image.i use database.
|
|
|
|
|
Hi Mir,
No Problem write like this
ThumbnailUrl='<%#"../Images/"+DropDownList1.SelectedValue+"/Thumbnail/"+DataBinder.Eval(Container.DataItem,"small") %>'
|
|
|
|
|
Thanks i have done it already.
|
|
|
|
|
Hi
how to pass xml file to web service
Thanks in advance .
|
|
|
|
|
I am getting error:-
An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)
I have done everything like Enabling tcp/ip,named pipes,no aliases r there,added User Instance=true in web.config in the connection string.
Pl help me out!
|
|
|
|
|
This is one of the common error for ado.net connection with SQL Server.
What version of SQL Server are you using ? is it SQL Express ?
Hope now you can get some workarroud from Google
cheers,
Abhijit
|
|
|
|
|
hi,
I have written a web-method under web-service which returns an array of string.
for some reason i am getting data through a WebRequest
I am able to get data but i am confused regarding the appearance of xml format
Please tell me why two string tags are appearing here
* it returns more than two rows
* i have removed the starting tag '<' as it was not getting posted properly
HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: length
soap:envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
soap:body>
getadsresponse xmlns="http://google.com/tiwarione/">
getadsresult>
string>string
string>string
/getadsresult>
/getadsresponse>
/soap:body>
/soap:envelope>
I will be thankful for the response
Thanks and regards
sindhu tiwari
If You win You need not Explain............
But If You Loose You Should not be there to Explain......
|
|
|
|
|
Me too
Try to post configuration section properly.
cheers,
Abhijit
|
|
|
|
|
I am doing a web application in which
i have XML file and data from it is bind to a gridview.
I have a Link button in Gridview under column UserName
On clicking name links, a ModalDialogbox opens which has some textboxes and buttons
I want values from the grid view in the page to populate into ModalDialogbox using javascript.....
the sample code i was using is
OnClientClick of Linkbutton
calls function
function EditUserForm()
{
var winopen = showModalDialog("AddUser.aspx?",window, "dialogLeft:250px;dialogTop:300px;dialogHeight:400px;dialogWidth:600px;center:no;help:no;resizable:yes;scroll:yes;status:no" );
}
Please help with some code sample....
Thanks in advance
SAJAN A PILLAI
ASP.NET,C#.NET Programmer
BANGALORE
"Winners don't do different things. They do things differently. ...
|
|
|
|
|
Accessing Controls of parent form in JavaScript of PopUp
<br />
var winobj=window.opener;<br />
txt2=winobj.document.getElementById('Textbox2');<br />
For Grid View Objects
Row Data bound add onclick of LinkButton add following attributes
<br />
LinkButton I1 = (LinkButton)(e.Row.FindControl("LinkButton"));<br />
I1.Attributes.Add("onClick", "OpenPopUp('" + I1.ClientID+ "');");<br />
Now in JavaScript you will get the ClientId of link button clicked
You can send it as a Query string
<br />
function OpenPopUp(mes)<br />
{ var mest=mes;<br />
alert(mes);<br />
window.open("WebTest.aspx?CntrlId="+mes,"WebPopUp",'width=200,height=200,location=yes');<br />
}<br />
Now in PopUp page assign this Id in some Hiddenfield
manipulate this value to retrieve id's of other grid controls
eg : Suppose u got Id of LinkBtn as GridView1_ctl00_ImageX
and in the same row u have a textbox with Id "txtname"
so it's ClientId will be DataList1_ctl00_txtname
u can access the textbox above as (A little string manipulation is required)
<br />
var winobj=window.opener;<br />
txt2=winobj.document.getElementById('DataList1_ctl00_txtname');<br />
modified on Tuesday, November 25, 2008 9:22 AM
|
|
|
|
|
Hi,
I am trying to write ASP.NET website that will have many features added to it as time passes, I want to add those features without changing the code, so I plan to use describtion variables in web.config for each added feature, for example:
feature: name="FeatureName" RegexFormat=@"\d+", etc..
Options: displayAds = "false", logErrors = "true", etc.
The question is:
1. Does loading variables from web.config file take much more time than embedding variables in the code? if so, does this time consuming task happen only when loading the variable for the 1st time and then it is cached in memory, or does it take much time everytime the variable is loaded? and what's the best way to implement such variables that are likely to change, but not in the near future?
2. How does the efficiency compare to storing these variables in a database instead of web.config.
P.S.: Those variables will be used heavily in the program.
Thanks alot
And ever has it been that love knows not its own depth until the hour of separation
Mohammad Gdeisat
|
|
|
|
|
Hi all,
I have downloaded the ajax toolkit, and followed all the steps shown in the video present on asp.net ...
but, still i m not able to use the Ajax controls,
when, i m running the Sample website, and try to test any control, i m getting following error
Could not load type 'System.Web.UI.ScriptReferenceBase' from assembly 'System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35'.
plz help me out of this ...
Apurv
A man is but the product of his thoughts. What he thinks, he becomes.
.......Mahatma Gandhi
Be the change you want to see in the world.
.......Mahatma Gandhi
|
|
|
|
|
Do you have the framework 3.5 sp1 installed?
|
|
|
|
|
First of all , error is not posted properly.
second things is that are you doing your project directly from IIS, means its running from local system or, you trying to run from IIS with in VS ?
cheers,
Abhijit
|
|
|
|
|
Abhijit Jana wrote: local system or, you trying to run from IIS with in VS ?
well ... i m running it on the local system ....
in Visual web developer 2008 express edition ...
Apurv
A man is but the product of his thoughts. What he thinks, he becomes.
.......Mahatma Gandhi
Be the change you want to see in the world.
.......Mahatma Gandhi
|
|
|
|
|
I am doing a web application in which
i have XML file and data from it is bind to a gridview.
I have a search button and textbox through which i have to find the records in XML file
that has the input matching records.
If i enter "Admin" and press search it should all records having "Admin" as user..
Please help with some code sample....
Thanks in advance
SAJAN A PILLAI
ASP.NET,C#.NET Programmer
BANGALORE
"Winners don't do different things. They do things differently. ...
|
|
|
|
|
U need to parse the XML string ,
but if you have already bound the data to grid view why not search it in grid itself .........
|
|
|
|
|
Can u provide me with some piece of code so that it would be helpful.
I have binded the XML file to grid now...i want to search a name and bind only those records to grid after search
SAJAN A PILLAI
ASP.NET,C#.NET Programmer
BANGALORE
"Winners don't do different things. They do things differently. ...
|
|
|
|
|
Hi,
I have an aspx page which is having an arraylist of audio file paths. A child window is opened in which the audio is played one by one. I have a timer control to identify when an audio file completes in the child window. Once the audio file completes, I have to close the child window and return to the parent. In the timer tick event, I have to close the child window. Please tell me how I can do this.
Thanks in advance
Subulakshmi
|
|
|
|