Search Results

Search found 4421 results on 177 pages for 'dynamically'.

Page 5/177 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Loading user control dynamically looses data

    - by user228777
    I have a created a user control. This user control I dynamically load on a page inside Telerik Panelbar control. I have done all necessary coding to save the viewstate and load this dynamically created usercontrol every time page loads. On this User control I have a asp panel. By default this panel is invisible. When user clicks a button on this user control panel is made visible. On page load of this user control I populate all the controls on this panel. Everything works fine if I don’t load this use control dynamically but when I load this user control dynamically and if I make panel visible by default then only all fields on the panel are populated. But if I make by default invisible and on button click make panel visible none of the text boxes or comboboxes are populated. I populate comboboxes on page load of the userControl but inbetween postbacks all the comboboxes on the user control loose data. ON the parent page I am saving the viewstate This is my code on parent page to dynamically load userControl ( which has panel on it) Dim ucPiggyBank As SubscriberSetupPages_UserControls_PiggyBank = CType(LoadControl("~/SubscriberSetupPages/UserControls/PiggyBank.ascx"), SubscriberSetupPages_UserControls_PiggyBank) With ucPiggyBank .PiggyBankID = account.Id .ID = account.Id.ToString 'Setting up following 3 properties here to avoid database trips .PiggyBankEligibleAccounts = piggyBankEligibleAccountCollection .MemorizedNames = memorizednames .Period = period End With radPanelNewChild.Controls.Add(ucPiggyBank) radPanelNew.Items.Add(radPanelNewChild) radPanelNew.Expanded = True ‘this is the Panel item on parent page of Telerik Panelbar control. Dim radPanelPiggyBank As RadPanelItem = DirectCast(pnlbarPiggyBank.FindItemByValue("TestItem"), RadPanelItem) With radPanelPiggyBank .Items.Add(radPanelNew) .DataBind() End With ‘I am doing everything for saving viewstate on parent control This is the code on page load of userControl If Not IsPostBack Then If m_PiggyBankID <> Guid.Empty Then 'Load data Call GetPiggyBankDetails() End If I have a edit button on the user control which makes panel visible. It makes panel visible but with no data. Can you please tell me what’s happening? Thanks in advance.

    Read the article

  • Ajax create div dynamically+javascript

    - by niao
    Greetings, The question relates to ASP.NET MVC I am creating some divs dynamically using AJAX (some views render dynamically). Inside these views a have some JS code. When user click on link i would like to open dialog box with google map. However, because these views are rendered dynamically it does not work because js code is not injected (what can be seen in page source). How can I resolve this problem?

    Read the article

  • How to dynamically edit dns entries without restarting the dns server

    - by satish
    I am trying to host multiple sites on a single webapp in a tomcat server. For example www.abc.com, www.xyz.com and several sites fetch content from my webapp hosted on tomcat with apache as the web server. My web app is hosted at www.mysite.com. www.abc.com should forward to www.mysite.com?id=abc www.xyz.com should forward to www.mysite.com?id=xyz Can you tell me how to configure dns entries, apache and tomcat configuration to achieve this scenario?? These site will have to be added dynamically! so is there any way to update the dns entries dynamically without restarting the dns server ... and similarly for apache and tomcat also?? Thanks very much in advance

    Read the article

  • Dynamically reference a Named Table Column via cell content in Excel

    - by rcphq
    How do I reference an Excel Table column dynamically in Excel 2007? ie: i wanna reference a named column of a named table and what table it is will vary with the value of a cell. I have a Table in Excel (Let's call it Table1). I want to reference one of its columns (Let's call it column1) dynamically from a value in another cell (A1) so that I can achieve the following result: When I change A1, the formula that counts Table1[DynamicallyReferencedColumnName] gets updated to the new reference. I tried using =Count(Table1[INDIRECT("$A$1")]) but Excel says the formula contains an error. Example: A1 = names then the formula would equal Count(Table1[names]). A1 = lastname then the formula would equal Count(Table1[lastname]).

    Read the article

  • Why isn't this button firing the anchor tag?

    - by Noor
    My idea is to press a button that takes me to a web page. I've created a thing that dynamically creates a button and an anchor tag. When the button is clicked, I want it to "click"/fire up the anchor tag.. I've uploaded a demo to my site, when you try it out just leave everything as it is. Click the first button then the add button right away.. then try to click the dynamically created button. Nothing happens, but if you watch the source you can find an anchor tag with the ID FL1000, I've set it up so that the anchor tag gets the ID from the value of the created button + 1000 just incase I need to use that ID.. Thanks guys... edit: this is optimized for google chrome, haven't tried it out with other browser.

    Read the article

  • Ruby metaclass madness

    - by t6d
    I'm stuck. I'm trying to dynamically define a class method and I can't wrap my head around the ruby metaclass model. Consider the following class: class Example def self.meta; (class << self; self; end); end def self.class_instance; self; end end Example.class_instance.class # => Class Example.meta.class # => Class Example.class_instance == Example # => true Example.class_instance == Example.meta # => false Obviously both methods return an instance of Class. But these two instances are not the same. They also have different ancestors: Example.meta.ancestors # => [Class, Module, Object, Kernel] Example.class_instance.ancestors # => [Example, Object, Kernel] Whats the point in making a difference between the metaclass and the class instance? I figured out, that I can send :define_method to the metaclass to dynamically define a method, but if I try to send it to the class instance it won't work. At least I could solve my problem, but I still want to understand why it is working this way.

    Read the article

  • Add dynamical elements in a Iframe element than i create

    - by serloro
    Hi, i have a litle problem if i create a dynamically IFRAME element and i agregate dynamically elements to the new iframe. It works If i do that: var miiframe=document.getElementById("miiframe"); var myElement=content.document.createElement("LABEL"); myElement.innerHTML="blabla"; miiframe.contentDocument.body.appendChild(myElement); but if i do that doesn't works: var miiframe=content.document.createElement("IFRAME"); miiframe.src="about:blank"; document.body.appendChild(miiframe); var myElement=content.document.createElement("LABEL"); myElement.innerHTML="blabla"; miiframe.contentDocument.body.appendChild(myElement); i see the iframe but i don't see the label element. The most courious is if before appendElement i do and alert it works!!! var miiframe=content.document.createElement("IFRAME"); miiframe.src="about:blank"; document.body.appendChild(miiframe); var myElement=content.document.createElement("LABEL"); myElement.innerHTML="blabla"; alert("now works!!!"); miiframe.contentDocument.body.appendChild(myElement); With DIV element works but i want do that with IFRAME element!!! Thanks!!

    Read the article

  • Dynamically loaded control - how can I access a value in Page_Init

    - by Sam
    I am loading a LinkButton dynamically when a user clicks on another LinkButton. I am attaching an event handler to it. When the user clicks on the dynamically loaded LinkButton, the event does not fire. From what I've been reading, I understand this is because when the page posts back the dynamically loaded control no longer exists. It looks like I'm supposed to make sure this control is recreated in Page_Init. The dynamically created LinkButton is dependedent on a value (Product ID). I need someway to access this value so I can properly create the control. ViewState is not accessible and I'm concerned if I use Session it could time out and then that wouldn't help. Any ideas? Also, I hardcoded a Product ID value just for testing, and that still did not cause the event to fire. Is there something else I need to do? protected void Page_Init(object sender, EventArgs e) { SetTabText(1, 1); } SetTabText calls SetActionLinks which creates the LinkButton: protected Panel SetActionLinks(int prodID, int tabID) { ... LinkButton lnkBtn = new LinkButton(); lnkBtn.ID = "lnkBtn" + rand.Next().ToString(); lnkBtn.CommandName = "action"; lnkBtn.Command += new CommandEventHandler(this.lnkAction_Command); panel.Controls.Add(lnkBtn); ... } void lnkAction_Command(object sender, CommandEventArgs e) { LinkButton btn = (LinkButton)sender; switch (btn.CommandArgument) { AddCart(); } }

    Read the article

  • Dynamically add event to custom control (Confirm Message Box)

    - by Nyein Nyein Chan Chan
    I have created a custom cofirm message box control and I created an event like this- [Category("Action")] [Description("Raised when the user clicks the button(ok)")] public event EventHandler Submit; protected virtual void OnSubmit(EventArgs e) { if (Submit != null) Submit(this, e); } The Event OnSubmit occurs when user click the OK button on the Confrim Box. void IPostBackEventHandler.RaisePostBackEvent(string eventArgument) { OnSubmit(e); } Now I am adding this OnSubmit Event Dynamically like this- In aspx- <my:ConfirmMessageBox ID="cfmTest" runat="server" ></my:ConfirmMessageBox> <asp:Button ID="btnCallMsg" runat="server" onclick="btnCallMsg_Click" /> <asp:TextBox ID="txtResult" runat="server" ></asp:TextBox> In cs- protected void btnCallMsg_Click(object sender, EventArgs e) { cfmTest.Submit += cfmTest_Submit;//Dynamically Add Event cfmTest.ShowConfirm("Are you sure to Save Data?"); //Show Confirm Message using Custom Control Message Box } protected void cfmTest_Submit(object sender, EventArgs e) { txtResult.Text = "User Confirmed";//I set the text to "User Confrimed" but it's not displayed txtResult.Focus();//I focus the textbox but I got Error } The Error I got is- System.InvalidOperationException was unhandled by user code Message="SetFocus can only be called before and during PreRender." Source="System.Web" So, when I dynamically add and fire custom control's event, there is an error in Web Control. If I add event in aspx file like this, <my:ConfirmMessageBox ID="cfmTest" runat="server" OnSubmit="cfmTest_Submit"></my:ConfirmMessageBox> There is no error and work fine. Can anybody help me to add event dynamically to custom control? Thanks.

    Read the article

  • Asp.net MVC dynamic generated Text Boxes

    - by Ashish
    I am creating a page with with some Text Boxes that are generated dynamically. Ids' of all text boxes are also generated at run time. I want to send all text boxes value to my controller and save that data. How I get all text boxes value. I may use javascript or JQuery. Can anyone suggest me? Thanks in advance.. Ashish

    Read the article

  • Protocol buffer deserialization and a dynamically loaded DLL in Compact Framework

    - by cloudraven
    I saw a question related to this on the full framework here. Since it seems to have stayed unresolved for quite a while and this is for the compact framework, I though it would be better to create a new question for it. I want to deserialize types for which I am loading assemblies dynamically (with Assembly.LoadFrom) and I am getting a "Unable to identify known-type for ProtoIncludeAttribute" error. In the related question I mentioned, it was hinted that hooking AppDomain.AssemblyResolve event would help solving the problem. It makes sense for the full framework, but that event is not available in the CF. I wonder if there is a way to do this with CF. The structures I am using look a lot like this and all the classes required for deserialization are loaded from the same Assembly. If the assembly is referenced instead of dynamically loaded it works fine, but fails if done dynamically.

    Read the article

  • Instantiating spring beans in dynamically created classes.

    - by Xetius
    I am dynamically creating classes which contain spring beans, however the beans are not getting instantiated or initialised, leaving them as null. How do I make sure that a dynamically created class creates all of its spring beans properly? This is how I am dynamically creating the class: Class ctransform; try { ctransform = Class.forName(strClassName); Method handleRequestMethod = findHandleRequestMethod(ctransform); if (handleRequestMethod != null) { return (Message<?>) handleRequestMethod.invoke(ctransform.newInstance(), message); } } This leaves all spring bean objects within ctransform (of type strClassName) as null.

    Read the article

  • jquery dynamically added checkbox not working with change() function

    - by estern
    I dynamically load in a few li's that have a label and a checkbox in them to another visible ul. I set the checkboxes to be checked="checked" and i am trying to trigger an event to happen when i change these dynamically inserted checkboxes but nothing occurs. Here is the jquery: $(".otherProductCheckbox:checkbox").change( function(){ alert('test'); }); Here is the html for the dynamically added li's: <li class="otherProduct"><input type="checkbox" class="otherProductCheckbox radioCheck" checked="checked"/><label>Product Name</label></li> Any idea why i cant get the alert to happen when the checkbox changes its checked state?

    Read the article

  • Dynamically hosting new domains on Apache

    - by Kunal
    I'd like to dynamically be able to host client's domains, with just having to provide them instructions like this: http://www.tumblr.com/docs/en/custom_domains I'm running a pretty typical LAMP stack; any good tutorials for configuring this for Apache, or other server-side configurations I need to be aware of?

    Read the article

  • In SSRS 2000 dynamically setting the datasource

    - by Christopher Kelly
    Is there a way in SSRS 2000 to set the datasource that a report is using via the webservice? I am currently generating reports using the SSRS2000_ReportService.ReportingService webservice and want to dynamically switch between a couple of shared data sources on demand. I am using C# but could adapt other languages if needed.

    Read the article

  • TypeError: Result of expression 'printWindow' [undefined] is not an object.

    - by orangebrainer
    I'm trying to create hidden iframes in my page dynamically to load 3 other pages so that i can grab all the HTML and combine them into 1 in a new window. However i'm stuck at this. tHe frames are created fine. But whenever the javascript runs to the part of function openNewWindow() { var printWindow = window.open("",""); printWindow.document.open(); printWindow.document.write(HTMLfromFrames); printWindow.document.close(); } i get this error: TypeError: Result of expression 'printWindow' [undefined] is not an object. but if i generate a button to call this function seperately, it works fine. however i need it to run all in one click event Anybody has any idea what's wrong? Thanks!

    Read the article

  • How to make instance of mxml and pass parameters?

    - by toshe
    i want to create instance of mxml (in my case EventList) and pass parameters. My Event List is a list of panels so I want to pass parameters and generate dynamically n number of panels (n-parameter to pass). I have the main app where I have toggle button bar when I click on the first I want for example to generate 3 panels (n=3) on the second button 20 panels (n=20) etc. How can I do this? How can I pass n and what is the best way to show the list? I whant to generate the list when I click on the toggle button!

    Read the article

  • ypeError: Result of expression 'printWindow' [undefined] is not an object.

    - by orangebrainer
    I'm trying to create hidden iframes in my page dynamically to load 3 other pages so that i can grab all the HTML and combine them into 1 in a new window. However i'm stuck at this. tHe frames are created fine. But whenever the javascript runs to the part of openNewWindow(); { var printWindow = window.open("",""); printWindow.document.open(); printWindow.document.write(HTMLfromFrames); printWindow.document.close(); } i get this error: TypeError: Result of expression 'printWindow' [undefined] is not an object. but if i generate a button to call this function seperately, it works fine. however i need it to run all in one click event Anybody as any idea what's wrong? Thanks!

    Read the article

  • Insert django form into template dynamically using javascript??

    - by qulzam
    I want to add same django form instance on same template. i already add one before and other add dynamically using javascript. for example 'form" is a django form: newcell.innerHTML = {{ form.firstname }}; The problem is that when i submit the form, in view the request object has only one value (that is not add using javascript). how can i get the values of other form elements values that is added dynamically runtime.

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >