Collect Variable Using Modal Window And Pass Into Function?

Dec 22, 2009

I have a function that returns a date. I want to use a modal window to get the datte value from the user and pass it into the function.

View 1 Replies


ADVERTISEMENT

Pass ID Parameter To An Aspx Modal Window?

Oct 16, 2011

I have a repeater control that contains a hyperlink which the user will click to launch a custom aspx modal window. The hyperlink contains the "record id" value.

The user clicks the hyperlink, the code passes from code behind to javascript, which launches the custom aspx window.

How do I pass the record id parameter from javascript function so that the aspx modal window being launched can retreieve it, and run a sql query with that value.

View 1 Replies

Calling A Javascript Function From A Modal Window?

Aug 21, 2011

I want to calling a javascript function from a asp.net modal window using vb. The javascript function is to close the same modal window. The function I want call is: function CloseModalWindow(winName)

I tried Page.ClientScript.RegisterStartupScript

but that does not work. How can I do that from vb.net code behind?

View 3 Replies

Use Window Like A Function / Pass In Parameters / Use Window / Get Data Out When It Closes?

Dec 13, 2011

I am creating a window that is a generic keypad for editing numerical values on a touchscreen. I would like to press an 'edit' button to create a copy of the keypad window/bring up a reusable version of the same window (I don't care), but pass in parameters: the old value I'm manipulating, and a title to be displayed above the number pad. I would like the user to be able to type in the new value, then press the 'done' key to submit this value and have it sent back to the main application window into my custom control that contains a text box.(I have the number pad's layout sorted out already; I'm already using a variation on it to set a global password 'access level'. It's getting the information in and out that has me scratching my head.) [code]

View 1 Replies

How To Pass Array Variable From Vba To Function

Mar 3, 2012

Im having a very difficult time trying to pass an vba array ive built from ms- access vba to a .net function.I don't have a com problem I can reference the library just fine from vba but and i can call a simple function from vba. however my problem exist when i attempt to try to pass an array to the vb.net function. vb.net code

View 3 Replies

Increase Variable Each Pass Through A Function

Jul 8, 2009

I have a variable that I am trying to get to iterate up by one, i.e. X starts at 0 x+1 on first pass thererfore its at 1 then x+1 on second function call therefore x=2 and so on. I've tried the different loop and for commands but I cant get one to stay until the next function call, does it need to be a global variable? I'm sorry if this is in poor form or improperly formatted, definently trial by fire going into the object oriented world.

View 9 Replies

Pass An Integer Variable From The Sub To The Function

Dec 18, 2009

I don't think I fully understand passing values from a sub to a module. Here is what I'm trying to do (problem is at the '****):

[Code]...

I think I've seen something like this before - where the actual function returns a value. Is this possible? Or would I have to pass an integer variable from the sub to the function, and then return it back to the sub?

View 3 Replies

Pass Array Variable From Vba To Function?

Mar 1, 2012

Im having a very difficult time trying to pass an vba array ive built from access vba to a .net function. I dont have a com problem I can reference the library just fine from vba but and i can call a simple function from vba. however my problem exist when i attempt to try to pass an array to the vb.net function. vb.net code

<ComClass(ComClass1.ClassId, ComClass1.InterfaceId, ComClass1.EventsId)> _
Public Class ComClass1
Public otag As String()

[code].....

View 1 Replies

Pass Variable To External Function?

Dec 12, 2009

I have been trying to correctly pass the value of a textbox as a variable to a function that reside in my App_Code folder when triggered by a click event. I can't seem to get it right.Here is the code behind for the aspx page with the textbox and the click event:(Error is on 4th line)

Public Sub btnCouponCode_Click1(ByVal sender As Object, ByVal e As System.EventArgs, Optional ByVal CouponCode As Char) Handles btnCouponCode.Click
lblSubtotal.Text = Calculations.CalcSubTotalPrice().ToString("C")

[code]......

View 4 Replies

Pass Structure Variable Array To Function?

Feb 2, 2012

I have a structure to hold a student name, an array to hold 5 test scores, and an average score. I have created an a array of structures for 6 students. User input is setup through text boxes. I want to calculate the average for each student. I have made a function to do this. What I am having trouble with is how to pass the array of test scores to the function.

Here is what I have so far:

CODE********
Public Const intMAX_STUDENTS As Integer = 6
Public Const intMAX_NUMTESTS As Integer = 5
Public student(intMAX_STUDENTS - 1) As StudentData

[Code].....

View 3 Replies

Take A Section Of The Xml File And Pass It As A Variable To Another Function?

Jun 5, 2012

I am using XML literals to parse files that contain data. I was wondering if there is a way to take a section of the xml file and pass it as a variable to another function...

<XML>
<DATA>
<STUFF>
<blahblah>sdfsdf</blahblah>

[code].....

I know with XML literals I can use ...<STUFF> and get the info out of that section, but how can I take an entire section of the xml, like MORESTUFF and set it as a variable to pass to another function that can parse that xml?

View 3 Replies

Forms - Pass Variable From Child To Parent Like A Function

May 23, 2012

I have created 2 forms (Parent & Child), i want to store the unique textbox value to a variable into the parent form.

[Code]...

View 2 Replies

Collect Info From PC Hostname And Pass Into Database

Jan 11, 2009

I am just trying to get the information i collect from the pc's hostname and pass it into a db. All the db passwords, location etc are correct but i am getting nothing.

Imports System
Imports Microsoft.Win32
Imports System.Data
Imports System.Data.SqlClient
Public Class Form1
Private Sub DB()
[Code] ......

View 14 Replies

Pass A Value Into A Modal Form?

Jan 29, 2012

I'm trying to pass a value from the main form, "form1" into "form2". I'm opening "form2" as a modal dialog from this line of code:

form2.ShowDialog()

View 4 Replies

Collect A Sequence Of Events In A Variable Of Some Sort

Jul 31, 2011

In my program; I need to collect a sequence of events in a variable of some sort. Each time the Sub is initiated, it should add one random event to the sequence (so that it gets longer each time) and then run through the sequence.This is rather difficult to express.What I'm trying to do, is create a Simon Says game with the four buttons.After the sequence goes through blinking the buttons, the program must then be able to capture the sequence of button presses by the user and match that to the sequence that the program ran.So, I need to be able to keep track of two sequences in a variable. Arrays?

View 3 Replies

Collect Information From Core Temp And Use It As A Variable Within VB?

Dec 25, 2011

collect information from core temp ( how to gain information about the CPU directly from the motherboard or windows E.G temperature CPU name ) and use it as a variable within VB.

View 3 Replies

Asp.net - Closing Modal Window Programmatically?

Apr 26, 2012

I have a modeal window that I am showing in .aspx. How do I close this modal window in VB.net programmatically?

View 1 Replies

.net Code - Track When A Modal Window Appears?

Dec 1, 2010

I am trying to automate with Coded UI . Now it runs fine but when an abrupt modal window / exception window appears , it halts and tries to act on it but this was not part of recording. I want to track when this modal window appears and then kill the AUT [ application that is being automated upon ].This will at-least prevent users from watching screen w/o any progress.

View 6 Replies

Expect Some Dialog Window To Appear In A Non-modal State?

Apr 19, 2009

If I type this code (VB.net 2003):

Dim myDialog As frmTestDialog
myDialog = New frmTestDialog
myDialog.Show()

you'd expect some dialog window to appear in a non-modal state. For some reason, this isn't the case with a program I am working on. Most of the dialogs use ShowDialog() to open them, and one uses Show(). The second I try to show another non-modal dialog, the dialog appears in a modal state. Another strange thing is, before I show the dialog, there is code to shift the dialog location to centre it on the main form - this isn't executed either: the dialog appears at 0,0.

My usual trend is to blame myself for errors (usually the case), then I blame the software; I have checked every single line of code (including the generated code), and it all checks out - the dialog should be non-modal. But ... it's not. I've come across other errors in VB.net 2003; is this another instance?


I'll try creating a new dialog and displaying this non-modal, and see what happens. If it works, I can just transplant the code but this shouldn't be happening, just like if I go to a shop, ask for a cola, I expect a cola not a Chinese panda; more annoying, I return the panda, ask for a cola, and they give me the panda back do loop until I give up The system does using threading, but none of that code connects to the display dialog routines all dialogs are opened with more-or-less the above code (a few have simple validation routines).

View 5 Replies

MessageBox Not Showing From Modal Dialog Window

Jul 5, 2011

I am trying to show a message box when an error occurs in a modal dialog window but for some reason the message box is never shown although I know the MessageBox.Show method is being hit. The try catch block is inside of an event handler for a windows form that is being shown as a modal dialog. I know that the event is being fired and that the error is being caught but the message box never opens. I've replaced the MessageBox.Show with another form show and it works fine but I'd rather use MessageBox instead of creating my own error form. I just can't seem to make MessageBox work. Is this a limitation of MessageBox? Here is a simplified version of what I am doing:

[Code]...

View 1 Replies

C# - Calling Modal Window From Asp.net Secure Site Links?

Jan 28, 2011

having a modal window spawn for a secure asp.net site. I currently have a asp test site setup which when the user clicks on the login link it opens the standard asp.net login page (login.aspx) within a modal telerik RadWindow. I am calling this page using javascript and this works fine.

The challenge I have now is when a user clicks on a link within the page if that link points to a secure section the login screen loads in the main frame of the site vs. a pop-up. I realize why (aka my js funciton is not being called) my question is to work around this would the correct/acceptible approach be to call a method from each link/button that tests for user authenticaiton? If the user is authenticated then redirect to the page otherwise call the javascript funciton to open the window?

UPDATE: I have some progress to now at least determine if the user is validated. Since I am using forsm auth I can test this using ISAUthenticated

public void LinkButton_Click(object sender, EventArgs e)
{
if (Request.IsAuthenticated == false)
{

[code]....

View 1 Replies

How To Pass A Function To A Function Is Functors/function Objects Avaiable In VB2010

Oct 12, 2011

I want to make an numerical integration method with takes in an analytic function and integrate it over a specific interval. For the numerical integration procedure I want to use some procedures in nr.com. The problem is that these are programmed in C++ and they uses functors to pass a function to the integration method. How can I do this in VB 2010?

I want to initialize the function (i.e. set a=1,b=0 for function y(x)=a*x+b) and then pass the function to the integration method. Then when the integration method call the function it only calls the function with one parameter (i.e. x since a,b is already set)

What is the best way to do this in VB2010?I want to make a general integration method where I can pass any single valued function and integration limits.

I have just started using VB, and from what I have found so far it seems like the tools you have is

- to us a delegate for the function
- to use a lambda expression for the function
- send a pointer/adressOf
- to create a function class/structure and submit this to the function

As for now I am most inclined to create a function-class. But I am not really sure how.F.ex. I make different classes for each "uniqe function" I want to integrate, but how can I pass them to the integration function when I need to specify the argument type in the integration-function-call?This seems like a basic problem which applies to many Math operations, so I think it would be very useful to clarify this.

View 2 Replies

Passing Variable From Windows Form To Modal?

Mar 28, 2012

Windows Forms, VB. I have searched the web for the correct answer to this and no dice. Either they are missing on what I am trying to accomplish or are in CSHARP making it harder for me to see what they are doing. I have a need to pass a record Id from the main windows form into a modal Dialog Load Event.. I have tried throwing a with param in but then I have to change the Load event params and vb flags it.. I am trying to pass the value of _CurrentProp which is an integer into the dialog. This is the dialog constructor and the load event inside that dialog..

[code]...

I am going to simply assign the value to a global variable inside the PropertySettings Class but everything I try seems to fail in one way or another...

View 1 Replies

Modal Window - Cannot Refresh Parent (Retry / Cancel Popup)

Jan 15, 2009

I am using modal window for my VB.NET program and I am trying to open this child modal window from another window, after I close the child modal window I am trying to refresh the parent but I am getting retry/cancel popup, I tried a lot of things to avoid but I can't get rid of this popup.

View 1 Replies

Pass A Variable To Another Form Or Else Make The Variable Visible To Both Forms?

Sep 5, 2010

Using Visual Basic 2008 Express. I need to pass a variable to another form. Or else make the variable visible to both forms.

View 4 Replies

Pass Function (Of TElement / TKey) As A Function Parameter

May 28, 2012

I want to make a GetAllContacts method which takes a sort parameter of type Func(Of Contact, TKey) which is the same type that the OrderBy method for an IEnumerable(Of Contact) takes.[code]"Too many arguments to extension method 'Public Function ElementAtOrDefault(index As Integer) As Contact' defined in 'System.Linq.Enumerable'." on the second parameter.

View 2 Replies

Pass A Value From A Sub Procedure To A Function Procedure .... Pass The Whole Subprocedure To The Function Procedure Argument?

Mar 30, 2012

Im a student doing an assignment, how do i pass the value from a sub procedure to a function procedure....i want to pass the value from decSubtotal to a function procedure named CalculateDiscount; check out my code--

[Code]...

View 1 Replies

Close A Modal Form From Who Initiated Modal One?

Feb 25, 2011

I have a parent form (form1), which is calling a second form (form2) as modal.[code]...

No form2 is modal. Closing this form2 from the form itself is clear.But how can I close the form via myform2.close from form1 via an event handler?

View 6 Replies

Program Function - Says, "The Type For Variable [variable] Will Not Be Inferred Because It Is Bound To A Field

May 18, 2012

Public Class Form1
Dim x, c, number(0 To 19) As Integer
Dim s As Integer

[CODE]...

The variables in the brackets [example] do not actually have brackets in them in the original code. These are where the issues are. For both variables, it says, "The type for variable [variable] will not be inferred because it is bound to a field in an enclosing scope. Either change the name of [variable], or use the fully qualified name (for example, 'Me.[variable]' or 'MyBase.[variable]')." Now, I'm not entirely sure if this is a stupid question or not, as I'm used to VB '98 because that's what we use in my programming class at High School. let me know why this won't work.

-Note: The intention of this program is to continually loop the generation of numbers for this list until I tell it to stop. Button1 ends the program, Button2 generates the list one time only, Button3 is supposed to loop the generation of the list, and Button4 is supposed to end the loop, but not the program.

View 9 Replies

Wpf - Call A Public Sub Function Of A Window From Another Window

Oct 20, 2009

I have A Wpf window with a Public Sub function(Window1). I need to execute that function from another window. Something like this:

Private Sub Window2_Loaded(ByVal sender As System.Object, ByVal e As System.Windows.RoutedEventArgs) Handles Window1.Loaded
Dim Window1 As New Window 1

[Code]....

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved