i want to execute some code every one minute like i select * from customers , now for each row, i want that each row will execute after 1  minute , in asp.net web application  not in windows application.
I have downloaded a jquery tool which creates overlay windows so here is the code which I want to trigger by calling a javascript function instead of a button or link.
The CSS
[Code]....
The HTML note the overlay is executing when i click the button i want this to be triggered on javascript function)
[Code]....
[Code]....
All i want to do is call a function lets say "ShowOverlay()" from my code behind using ClientRegisterScript() and it should do the same as it is doing on button.
how to execute the code behind function using JavaScript keypress ?
The reason is that the keypress that I'm referring to will be used in searching record so I want that every keypress a result will be shown in the gridview immediately.
I'm trying to understand how to execute AJAX animation on an asp button that has to execute code on Postback. In other words, I have button with code behind that needs to be excuted, but at the same time want to be able to have one of animation extenders be applied to it. I understand that I need to use the BeginRequest Event, I'm just not sure how, or which javascript commands to use to call the ajax animation so the postback will still occur.
I have a flashcontrol that downloads a file. Around this flashcontrol I have put a <div>. What I am trying to do is to execute a click event in C# when this flashcontrol is clicked but the function in C# (func1) is not executing. How could this be possible to do ?
I'm creating a HyperLink dynamically in my code behind based on a database table. What I'd like to do, is that whenever someone clicks the link, a function is executed that then does some processing before rerouting them to the linked page.
Is there a way to do this? I don't want the look of a button, even though I suppose that's the functionality I want.
I have a page that calculates some stuff and then displays it to the user. Because the calculation part takes a while I would prefer to have the entire page load with empty data and only after that call the calculation and the display data function.
I only want to execute this JavaScript function runEx() if publicVarFromCodeBehind != "abc".
I am setting the publicVarFromCodeBehind = "abc" in the Page_Load event but anyway the runEx() function is executing. I wonder how this works and how to prevent runEx() from executing though I need to catch the logic from C# and pass on the variable to the JavaScript.
I have created javascript function as mentioned below to hide/show some control. I am calling this script on dropdown on 'onchange' method. In dropdown first item is "-- Select --". I want to execute it on Page Load function, so by default it will be hidden. I tried to call like this on Page load, but it is not working.
I am using a Timer with a 3 minutes interval. I am exeuting the Page_Load event every 3 minutes. I am doing that this way as I have all this code inside an UpdatePanel1 which causes
a partial unnoticed postback to the server. I have a lot of code in the Page_Load event that I haven´t put here.
But what does not work is the code I have in the Page_Load event now.
I am trying to execute the javascript function with this line: body1.Attributes.Add("Onload", "startbk()");
This function should start an imageButton to change image between 2 images. This function do works if I refresh the page so the function itself do works.
But it seems this function does not execute when the Timer executes the Page_Load event, so this is my problem how I can solve this?
How can I trigger a jQuery function with the Gridview Select button? I want that the select button trigger the jquery function that has the row details (it's already working with a asp:buttonfield ), and select the row so i can get the values and send it trough e-mail with another button. I don't know if this is possible. or, Can I trigger the jQuery function from code behind with the select button Sub? How?
[Code]....
This function capture the gridview cell values that are hidden and show them in a div outside the gridview (it works as row details). I have no problem with this.
[Code]....
All i need is a button that select the row index and/or values and trigger the jquery function . Or I can execute the jQuery function from server side. I don't know if it's posible.
I am developing a remote control application where a client (aspx page in a browser) can request a server to "launch a notepad" (for testing purpose, for real life, turning off a light bulb, etc). So I created a dll with a simple function for launching the notepad (on the server side) and dropped this dll in the root bin folder.
It worked fine when the aspx page is running under ASP.NET development server (launched from Visual Studio). But when I tested the same aspx page under a FireFox browser, it did not work (launch the notepad) even though it did call for the same function (I stepped through in debugger).
Is this a permission issue? How do I set this up in IIS manager, or even better in web.config?
1. How can I create a delay in C#.I know Thread.Sleep(0) but it is blocking my GUI.2. Also I need to pause the execution of the normal flow until a function return a result.
I have a page with some custom validation which displays a result in a validation summary. I would like to reposition this validation summary to the bottum of the page without causing the page to scroll with the length of the validation summary. I have a jQuery function which does this very nicely, however, I need to execute this jQuery after the validation summary is displayed and i'm not sure which event to trigger.
$(document).ready(function(){ $("#<%= vsmSummary.ClientID %>").change(function(){ var newTop = $(window).height() - $("#vsmSummary").height(); var newLeft = ($(window).width() - $("#vsmSummary").width()) / 2; $("#vsmSummary").css( { 'position': 'absolute', 'left': newLeft, 'top': newTop } ); }); }); In my custom validation method I build this string and register with the RadScriptManager... Dim scriptText As String = "$(document).ready(function(){ " + _ "$(""#<%= vsmSummary.ClientID %>"").ready(function(){" + _ "var newTop = $(window).height() - $(""#vsmSummary"").height();" + _ "var newLeft = ($(window).width() - $(""#vsmSummary"").width()) / 2;" + _ "$(""#vsmSummary"").css(" + _ "{" + _ "'position': 'absolute'," + _ "'left': newLeft," + _ "'top': newTop" + _ "}" + _ ");" + _ "});" + _ "});"
RadScriptManager.RegisterClientScriptBlock(Me.upSCPPage, Me.upSCPPage.GetType(), "DynamicVSM", scriptText, True) This works!! I had no clue that I could call this from my code behind!! I will be doing this much more in the future!
I'm developing a web application that displays items from a work queue to a user. When an item is selected I have the app lock that item out so no other user can select it. By hitting the back button in the app it unlocks the item.
I want to be able to unlock the item if the user hits the backspace key. I know what code I need to unlock it. I just need to know how to make the code execute on backspace key stroke.
I have a web app that needs to do two things at the same time. After a user clicks a button on the site, a javascript function needs to execute and while thats working I need the server side code for the button click to execute without waiting on the client side to finish.
To be more specific, the client side function takes about 23 seconds to complete, and while that is running the server side code promts the user for printing a document. So I need the javascript to run "in the background".
When i execute this SP in DB, it works fine. But when i execute from asp.net app it is throwing error: Procedure or function ... has too many arguments specified
GO SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO ALTER PROC [dbo].[sp_Customer] @brchID char(40), @brchName VARCHAR(50), @userID VARCHAR(50) AS BEGIN TRANSACTION DECLARE @req_pk int DECLARE @customer_org_pk int IF EXISTS(SELECT * FROM [customer] WHERE [org_id] like @brchID) BEGIN SELECT [org_pk] FROM [customer] WHERE [org_id] like @brchID END ELSE BEGIN EXEC sp_get_next_control_no 'organization.org_pk',@customer_org_pk out; INSERT INTO [customer] (org_pk,[org_id],[org_name]) VALUES(@customer_org_pk,@brchID,@brchName) SELECT [org_pk] FROM [customer] WHERE [org_id] like @brchID END --Address Book Entry IF NOT EXISTS(SELECT * FROM [address_book] WHERE [prsn_id] like @userID) BEGIN exec sp_get_next_control_no 'person.prsn_pk',@req_pk out; END IF (@@ERROR <> 0) BEGIN -- Rollback the transaction ROLLBACK RETURN END ELSE BEGIN COMMIT END
Here is my asp method:
public static string Customer(string brchId, string brchName, string userId) { string spName = "st_Customer"; SqlParameter OrgPk = new SqlParameter("@org_pk", SqlDbType.Int); OrgPk.Direction = ParameterDirection.Output; OrgPk.Size = 50; try { SqlHelper.ExecuteNonQuery(Config.ConnectionString, CommandType.StoredProcedure, spName, new SqlParameter("@brchID", brchId), new SqlParameter("@brchName", brchName), new SqlParameter("@userID", userId), OrgPk ); return Convert.ToString(OrgPk.Value); } }
I have written a code to download a file . I require that if the file is successfully downloaded on the clients then only certain code should be executed otherwise not.