Computing Data Through Function X - VarZ

Dec 7, 2009

I have a server that runs a thread that computes some data through function X. Then I have a client that communicates with the server and gets results from function Y. Now, both function (X and Y) share a common variable lets say varZ. When function X populates varZ when the thread starts on the server, the results are not propagated on function Y when accessed by the client through Remoting. But on the server side the results are correct in function Y! It's almost like when client calls function Y, it has no idea what is happening varZ is as far as the value set by function X thread in the server.

View 2 Replies


ADVERTISEMENT

Error In The Code Computing Totient Function

Nov 24, 2010

i made application for computing totient function but it doesn't give me any result this is a code Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click

[Code]...

View 1 Replies

Error In The Code Computing Totient Function?

Jan 12, 2010

i made application for computing totient functionbut it doesn't give me any result

this is a code
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click

[code]......

View 11 Replies

C# - A Value Larger Than ULong - Computing 100?

Aug 12, 2009

I'm trying to compute 100! and there doesn't seem to be a built-in factorial function. So, I've written:

Protected Sub ComputeFactorial(ByVal n As ULong)
Dim factorial As ULong = 1
Dim i As Integer
For i = 1 To n

[code]....

Unfortunately, running this with the value of 100 for n rseults in

Value was either too large or too small for a UInt64.

So, is there a larger data type for holding numbers? Am i mistaken in my methods?

View 5 Replies

C# - Heavy Computing On Remote Pc?

May 8, 2012

I love to experiment with linqpad, but now my task requires heavy computing power. Trying to do it on my computer is painful. My friend has a much more powerful computer than I -- can I execute some operations from my linqpad on his computer? I don't have RDP access, but I can run any .NET program on his computer.

If it is not possible, then is there any FREE service that provides computing power? Maybe a hosting trial or something. I know that Windows Azure offers a 30-day trial, but it has a very slow CPU module and in my country, MS partners cannot be expected to fix service sites when they go down.

View 2 Replies

Computing A Win/Loss Percentage?

Feb 19, 2009

I need to compute the percentage of games won and games lost. I keep getting errors and it's driving me up a wall. I've changed my code so many times that I don't really remember what it was like when I started.

Private Sub btnPercentage_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnPercentage.Click
Dim team As String

[Code].....

View 6 Replies

Computing Totals And Averages

Jun 14, 2010

How would you take a numerical input from 10 text boxes and total it up and send it to a label. Then average the 10 numeric text boxes and send it to its own label. I am not asking for any code, I just need a hint or two to jog my memory. If this is not clear for you, I'll provide more detail.

View 1 Replies

Distributed Computing With Mdf Files

Oct 16, 2010

I am using SQL EXPRESS EDITION 2005 and Created mdf data file using vb.net 2008. now i want to use this datafile in lan. i modified connection string "Data Source=.SQLEXPRESS;AttachDbFilename=ServerDataData1.mdf;Integrated Security=True;User Instance=True;Connect Timeout=60"it is showing security info error i want to use single database file for my application please help me with connection string. thank you

View 1 Replies

Vision And Parallel Computing?

May 26, 2010

i am trying to make a robot that i can talk to(not yet) and tell it to goto places 1st task it to figure out how to use an inbuilt webcam in my net book and do an image Recognition for walls stars eg 2nd task is to see if i can get it to use my server to help compute the images because my net book is very slow 3rd is speech to text now can all of these be done in vb.net?

View 2 Replies

A-Level Computing Exam Arghhh

Mar 6, 2011

I have been given the prep material for my AS Level (Year 12) computer programming exam based around dice cricket. Written in VB 2008.

In the exam we are supposed to change bits based upon the scenario. The scenario and skeleton code are attached.

I have looked through the code so far and made some guesses to what I think may be on the test:

[code...]

if there is anything I am missing which they think I could be asked on the test. I then have to go away and figure out how to program.

So by asking on here, I am not trying to find out coding answers - I do want to figure that out myself. I just want to see if there is anything else I possibly could be asked?

View 9 Replies

Arrays / Lists And Computing HashValues

Jun 13, 2010

I've had experience with using hashvalues from String objects. E.g., if I have StringA and StringB both equal to "foo", they'll both compute out the same hashvalue, because they're set to equal values. Now what if I have a List, with T being a native data type. If I tried to compute the hashvalue of ListA and ListB, assuming that they'd both be the same size and contain the same information, wouldn't they have equal hashvalues as well?

Assuming as sample dataset of 'byte' with a length of 5
{5,2,0,1,3}

View 3 Replies

C# - Computing EField Around A Point In A Ring?

May 31, 2011

I am trying to write code to compute the Efield on a point P in both the x and y direction, from a charged ring. double y_eField = (_ke_value * _dq * (Sin_angle) / (Math.Pow(r, r)));Problem I am having is the code seems to follow the equation as given but the result it outputs is not correct at all.

View 2 Replies

Coding Computing Project For A-Level?

Oct 24, 2009

I have just started coding my Computing project for my A-Level, and I will admit, I am far more experienced in VB6 than VB.NET (as embarrassing as that is to say).I get extra marks for making everything presentable, so was wondering if it was possible to add icons into .NET buttons. For example if I have a button to add an entry to the database, I want a nice Web 2.0 looking icon (for which I already have) next to the text on that button.

View 1 Replies

Computing And Saving Column Rows On A Datagirdview

Jul 7, 2010

trying to understand DataGridView. I can sum columns with no problems and place the result in a textbox. My problem is multipling two column rows and saving it. I receive the following error when I go to save it. "Column mapping from source column failed because the data column is a computed column. So can I compute two column row to a third and save it, if so how. My code is below:

I save.[code....]

View 10 Replies

Making A Login Form On .net For A2 Computing Coursework?

Feb 4, 2010

I'm struggling with making a log in form on vb.net for my A2 computing coursework.

Public Class DbConn
Dim connection As OleDbConnection
Dim cmd As OleDbCommand
Dim dataReader As OleDbDataReader

[code].....

View 2 Replies

VS 2008 Arrays And Loops - Computing Average Monthly Rainfall

Dec 2, 2010

I need to create an console application that computes the average monthly rainfall, number of months with above average rainfall, and the number of months with below average rainfall, given the rainfall amounts for each month in a particular year. The program must read in and store in an array the monthly rainfall amounts entered by the user one by one.

So far this is what I have got
Const intMonths As Integer = 11 'Constant Month variable
Dim sngRainfall(intMonths) As Single 'Rain for the month
Dim intCount As Integer ' Loop Counter
Dim sngTotalRainfall, sngAvgRainfall As Single 'Total and Average Rainfall
[Code] .....

How to set this up properly and I am having a real hard time figuring out how to make the data go from this loop to another and add the data to the total.

View 15 Replies

Computing Totals : Have To Compute The Differences From Each Campus Enrollment By Semester In 1 2D Array?

Aug 2, 2011

I have everything except the calculation for the increase or decrease in enrollment. Not sure how to handle this in a 2D array. (online class is not

Module Module1
Dim campus() As String = {"Decatur Day ", "Decatur Evening ", "Huntsville Day ", "Huntsville Evening ", "Distance Learning "}
Dim semester() As String = {"Fall 2010 Semester: ", "Spring 2011 Semester: "}

[code]....

View 5 Replies

Complete My "home Work" Assignment For My A-Level Computing?

Feb 4, 2009

I'm not looking for anyone to complete my "home work" assignment for my A-Level computing as I've done this now and I think it's impressive. What I am now looking for is help in extending what I have done and making it better.

History:I have built my application in Visual Basic 2005 Express Edition. It is a Console Application. After filling in the questionnaire the user gets given results and all this information is stored in a .txt document (Notepad). I want the data that is put in to the application to send infomation to the user's e-mail address. I have been looking around the internet and it says it could do it but it needs Outlook express.

View 3 Replies

Create A Function Which Have Either 1 Parameter With A String As Data Type Or 2 Parameters With Double As Data Type?

Jun 11, 2012

I need to create a function which have either 1 parameter with a string as data type or 2 parameters with double as data type.Something like the substring method.

View 2 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

Paste Data Using Function Key?

Jan 25, 2010

i want to create a program in which i want to use function key like F12, F11 i mean to say when i press F11 or F12 a particular code is paste in text box. when i used this method in my own form text box it works but i want to use it another window like google search box or
notepad. when i press F11 in notepad then my code should be pasted on that page

View 1 Replies

Pulling Data Into VB From SQL Function?

Feb 24, 2009

I have a table in my SQL DB that contains :- ID- Date From- Date ToI then have a SQL function that pulls out the Start Date (See code below)

View 1 Replies

Retrieve SQL Data In Function?

Jun 14, 2010

i have written the following code to retrieve a value from a sql database en return it in the function.it keeps giving me the following error "executereader:connection property has not been initialized"

View 1 Replies

Function Syntax - Call A Function With 2 Arguments When The Function Is Only Defined For One

Apr 1, 2010

I'm trying to undersatnd the syntax of calling a funciton and it seem confusing when I'm using a web service in ASP.net. Maybe this question should be in an ASP forum, but it is a VB question. This simple web service allows you to type in your name and it response with an alert box with you name.

My question is, How can you call a function with 2 arguments when the function is only defined for one. I understand that the second argument is actually a method that handling the respons, but how can you interchange function arguments for methods and how do you know that there are methods for

Here's my call:

<script type="text/javascript">

function HelloWorld()
{

var yourName = $get('txtYourName').value;

[CODE]...

View 7 Replies

Call Function Parameter Data?

Feb 3, 2012

I have had some trouble on what to put inside the parameter named CallFWT as without it i would get a value of 0[code]...

View 2 Replies

Calling Function On DLL To Get Data From Structure?

Apr 16, 2012

I have problem about how I call a function on DLL to get data from a structure. Have a C++ example about how it's works the library, and I want to use it on vb.net. his is the working c++ example:

Declaration:
BOOL (WINAPIV* MyFun)(DWORD start1, DWORD stop1, P_RESULT pResult, PDWORD pTpNum, myCALLBACK lpFunc) = NULL;

Call:
// pStruc = RESULT structure
// TrpNum1, TrpNum is ULONG
ULONG TrpNum1=0;
MyFun(Start,Stop,pStruc+TrpNum,&TrpNum1,&myCB);

Callback:
void __stdcall myCB (RESULT *pStruc) {
printf ("%.3f", (double)pStruc->val1);
tpn++;
[Code] .....

The error is this: "Attempted to read or write protected memory. This often indicates that other memory is corrupt."

View 1 Replies

Getting Data From Shared Function To Instances

Jan 24, 2011

VB.NET 2010, .NET 4. I am working on an application for controlling an industrial machine composed of many devices attached to the computer. Most if it is reasonable straight forward, but I'm having trouble thinking about the RS-232 devices. One of the RS-232 devices is a fancy power supply with many functions. The ones that are relevant right now are voltage read, voltage write, current read, and current write. The design pattern I'm trying to implement is one in which each attached device is represented by an object that has methods for reading/writing etc and properties for things like COM port etc.

For this power supply, clearly the Port reference should be shared among the instances, so I have a base class (say, PowerSupply) with a Protected Shared Property Port As IO.Ports.SerialPort. Then I have a couple classes that inherit from this class, PowerSupplyVoltage and PowerSupplyCurrent that each define read/write methods and properties for holding the last read/written values. My issue is in parsing the response from the power supply using the Port.DataRecieved event on the shared SerialPort object. The protocol the power supply uses specifies what data it's sending in each response packet.

So, basically, it might say something equivalent to "The voltage is 100V" or "The current is 1A" or "The voltage has been set to 150V" etc. I'm trying to parse this in a shared function. Only during the parsing process would I determine which instance's read/written value to update. I can't access the read/written value properties of the instances from within the shared function. The best I could think of is creating some kind of PowerSupplyCommunicator object that would maintain references to PowerSupplyVoltage and PowerSupplyCurrent instances along with the shared Port and DataRecievedHandler functions.

View 1 Replies

Hash Function For 2D Barcode Data?

Mar 16, 2011

I am writing a string of about 120 characters to a 2D barcode. Along with other text, the string contains a unique ticket number. I want to ensure that someone doesn't generate counterfeit tickets by reading the 2D barcode and generation their own barcoded tickets.

I would like to hash the string and append the hash value to what gets embedded in the barcode. That way I can compare the two on reading and see if the data had been tampered with. I have seen several hash function that return 64 bytes and up but the more characters you embed in a 2D barcode the bigger the barcode image becomes. I would like an algorithm that returns a fairly small value. It would also be nice if I could provide the function my own key. Collision is not that big of a deal. This isn't any kind of national security application.

View 1 Replies

Module Returning Data Like A Function?

Jul 12, 2010

How could I call a module or something else to return data to me after its ran. I don't want to make my form1 code all messy.

Public Function Test() As String
Return "Tes34t"
End Function

[code]....

View 2 Replies

Send Data To Function In Code Behind?

Jun 7, 2011

I have a modal/dialog with two buttons, "OK" and Cancel. When I hit "OK" I want to send these data to a function on the server. How can I accomplish this? Can anyone give me some information/example? I belive I would have to use "$.post" but again, how would I send it to a particular page's function?

UPDATED ... still cannot reach code behind function.
$('#dialog').dialog({
modal: true,

[code].....

View 3 Replies







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