|
IFrame is a HTML componenet. I has nothing to do with ASP.NET. You can deal this with javascript. Get IFrame object using Javascript, then use src to set the IFrame URL.
Hope this helps
|
|
|
|
|
Hi everyone.
I've been handed a Web application that dynamically loads custom UserControls.
Upon a useraction, clicking a link to a given "page" (UserControl), I instanciate the
control using the Page.LoadControl method, store it to Session["Control"], and add it to PlaceHolder.Controls.
This seemed to work out perfectly as the control was maintained on the postback and the state was also maintained. But after I started implementing a button eventhandler I noticed that the event is never caught when the button is clicked and the control refreshes.
I'm not that familiar with Asp.Net as I usually work with windows applications and services.
Could anyone please point me in the right direction of how to avoid loosing the event in the postback?
Best regards!
-Larantz-
|
|
|
|
|
Hey
First things first - check that the event is wired up correctly - think off the top of my head this is done in oninit or some other initialisation function within the page:
http://msdn2.microsoft.com/en-us/library/ms743596.aspx
If this doesnt fix it then make sure that ISS is using the correct version of .NET. If this doesnt work then google asp.net event not firing as there is loads of help (I had this problem too) - i cant remember how i changed the version of .NET but it is in the properties.
Hope this helps
Dan
|
|
|
|
|
i have a date .can i convert the month into monthname
Soniagupta1@yahoo.co.in
Yahoo Messenger Id = soniagupta1
|
|
|
|
|
Call the ToString(String) method on your DateTime structure, passing in a format string of "MMMM".
Paul Marfleet
|
|
|
|
|
ThanQ
Soniagupta1@yahoo.co.in
Yahoo Messenger Id = soniagupta1
|
|
|
|
|
hi,
I have taken two file upload control (fileUpload1 and fileUpload2) and two required field validator(requiredFieldValidator1 and requiredFieldValidator2) for the two upload controls mentioned above.i.e requiredFieldValidator1 for fileUpload1 and requiredFieldValidator2 for fileUpload2.Now there are two button btnUpload1 and btnUpload2 for two controls.i.e btnUpload1 is for uploading file of name given to fileUpload1 control and btnUpload2 is for uploading file of the name given to fileUpload2.Now what is happening is that when i gave valid file name in fileUpload1 and clicked btnUpload1, it also checks for fileUpload2 and depending on its container, it is throwing exceptions.Like if fileUpload2 has file name given, no error but when there is no file name given in fileUpload2, it is giving error.However, the requiredFieldValidator1 shouldn't check for fileUpload2.The control to validate for requiredFieldValidator1 is fileUpload1 and for requiredFieldValidator2 is fileUpload2. And the same error comes when i try to upload the file of fileUpload2 and click btnUpload2.Well i am using ASP DOT NET 2005 using C# . But when i use only one Required Field Validator, it works fairly..Why this error is coming when using two Required Field Validator...How to solve this ...
suchitamanandhar@hotmail.com
|
|
|
|
|
You could use a CustomValidator control instead. Write your own client-side validation function in JavaScript and link it to the control by setting its ClientValidationFunction[^] property. Your function should incorporate some logic that checks which button has been clicked and only performs validation for the FileUpload control associated with this button.
Paul Marfleet
|
|
|
|
|
Hi,
Thanx for you response....
I didn't understand about linking javascript link to the control...Can you give me the step by step process for that...Actually how the javascript should be ?? And how to return values ?? Can you please explain this in even more simple way ???
Regards,
Suchita
suchitamanandhar@hotmail.com
|
|
|
|
|
You need to Set Validationgroup Property of the control.
set FileUploadControl1,ReuiredFieldValidator1 and Button1 as "Group1" and FileUploadControl2,ReuiredFieldValidator2 and Button2 as "Group2"
Best Regard
Pathan
please don't forget to vote on the post that helped you.
|
|
|
|
|
Hello Pathan,
Thanx for your quick response .Ya, i have tried setting validationgroup property like the one you have suggested ..But it also doesn't work.No any affects shown by the required field validator.The same problem is coming ....So any more methods to implements???Any idea ??Hope to hear from you soon....
Regards,
Suchita
-- modified at 1:46 Wednesday 3rd October, 2007
suchitamanandhar@hotmail.com
|
|
|
|
|
hi all
when i use Asp configuration site to create user or group there is a database created in my site
in this path App_Data>>ASPNETDB.MDF
can i put this database in my sql server not in the site in the previous path
because i want to use and link user with some action in my application
thaks all
Kareem Elhosseny
|
|
|
|
|
i want to display google search results in asp page.here i displayed google results by using html,java script.but i run another result display time also displays.
so plz send code in c# to display google results in our page
venkat
|
|
|
|
|
Well, all you need to do is form a google search URL including the search terms and pass it to your browser.
venky456 wrote: but i run another result display time also displays.
I can't work out what this bit means ?
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
i am dispaying google search results with code project code.whisi was usd by twohiddenfields and javascript.it displays results well.the problem is it was used in indexing server .when i use radiobutton1 checked then my site search results.if i set radiobutton2 then google results displayed.it write under button control.
if once i choose google results if next i choose mysite results .then also displaying google& mysite results.
Here script run at each page load time.display results of google.for ur understanding see google co-operative search results in code project.
plz send code for this asap
thanks
venkat
|
|
|
|
|
i am using the view in stored procedure.
I the view i am using a query like
select * from t whee id=2
this view i being used in the stored procedure
can i pass the parameterin the stored procedure for the id.i mean id i already mentioned in the view, i want to mention this id in stored procedure as a parameter .how can i do that
Soniagupta1@yahoo.co.in
Yahoo Messenger Id = soniagupta1
|
|
|
|
|
you should have posted this question in the SQL forum.
Sonia Gupta wrote: can i pass the parameterin the stored procedure for the id.
There are no restrictions imposed on sql server to pass parameter (ID) to the stored procedure.
Sonia Gupta wrote: how can i do that
Create Procedure [ProcedureName]<br />
@Parameter datatype<br />
AS<br />
[Sqlstatements...]<br />
GO
Regards J O H N
"Even eagles need a push." David McNally
|
|
|
|
|
in stored procedure i am calling the views.
i am not writing the sql statements there.
Soniagupta1@yahoo.co.in
Yahoo Messenger Id = soniagupta1
|
|
|
|
|
Sonia Gupta wrote: in stored procedure i am calling the views.
i am not writing the sql statements there.
calling the View? I have not heard about it. All that I know is to USE the View. View is a Virtual Table. It provide's an alternative way to look at the Actual table.
And Inorder to Use the View in the stored procedure you have to write an Sql statement.
Can we have this disscussion in the Sql Forum?
Regards J O H N
"Even eagles need a push." David McNally
|
|
|
|
|
hi
you want to select an special row of view from storepeocedur ?
just pass the parameter to storeprocedure and then in storprocedure
call the view with a select .. where ..
sepel
|
|
|
|
|
ThanQ
Soniagupta1@yahoo.co.in
Yahoo Messenger Id = soniagupta1
|
|
|
|
|
All,
Can i loop through a dataset using my client side script(Javascript). Actually i am trying to implement a search, a particular view of dataset is bound to a datagrid. if the keyword in not in the grid, i have to extend the search to the whole dataset. Please provide some clue...
any suggection would be appreciated.........
Thanks for your time
Sebastian
|
|
|
|
|
Sebastian T Xavier wrote: Can i loop through a dataset using my client side script(Javascript).
No.You can't. There is no Dataset object in Javascript and the Dataset which you are talking is not accessible on the client-side.
Sebastian T Xavier wrote: Actually i am trying to implement a search, a particular view of dataset is bound to a datagrid. if the keyword in not in the grid, i have to extend the search to the whole dataset. Please provide some clue...
DataGrid is rendered to the client as a HTML Table. Through Javascript You can loop the items of the table...
Regards J O H N
"Even eagles need a push." David McNally
|
|
|
|
|
Hi John,
Thanks for the reply.
The whole dataset is not bound to the grid, (if it was , i could have search it cool) , only a particular view (say data with the location id 7) is bound to the grid. I have to search for a keyword (say asp) in the grid & if it is not in the grid , i have to search in the whole dataset.
Thats the scenario....will you be able to give more sparkles.....
Thanks once again
Sebastian
|
|
|
|
|
Sebastian T Xavier wrote: if it is not in the grid , i have to search in the whole dataset.
you have to do this on the server-side. Instead of searching the Dataset, you can search in the Database and get the result. Because when you do a post-back for a search, you need to query the Database again to fill the Dataset, right? I suggest you to write a stored proc on the database side which will return the search result.
Regards J O H N
"Even eagles need a push." David McNally
|
|
|
|