Hi every one . Recently i complete my project on libraray managment system which work perpectly on my system. Now the problem is that when i Execute my project on other system it show error at con.open i.e it mean that connection string not set in this system . Now i need code for how i set the connection i.e when i execute the project .exe it show me a form in which there is Database name , Server name , User name and Password . And after clicking the OK button it pass these value to connection string and …

Member Avatar
Member Avatar
+0 forum 14

I'm creating an application that with continuously attempt to run a list of programs until they are open. I'm having an issue when it comes to programs that require administrative priveleges however. I've done some searching and found the below script (in createElevationScript()) that *should* run a program with administrative priveleges, however it doesn't start the program successfully. Here's the relevant code: public void tryStart() { if (!checkRunning()) { try { ProcessBuilder processBuilder = new ProcessBuilder(); processBuilder.command(path); processBuilder.start(); } catch (IOException e) { System.out.println("ForceStartUp: Insufficient privileges to run ProgramEntry with Name '" + name + "' at Path '" + …

Member Avatar
Member Avatar
+0 forum 5

*I wrote these problems last night (except 19th problem), and code them at the morning, so, hope you all enjoy coding. This is ordiginal post of these 20 problems. Any question about the clarity of problems please post on below or contact me via pm, and your solutions too.* *If you are beginner and you can solve these 20 problems by yourself, you are really a genius programmer with a very bright future ahead.* *Although these problems (except 19th problem) I wrote last night but some of them might still familiar with you, some are ordiginal, some are mix-up or …

Member Avatar
Member Avatar
+0 forum 2

I am trying to add a coloumn from database into a listbox in VB6. The following code works. The selected item from this listbox is used to find and add records to the ListBox2. Using Oracle 11g Express Edition and Visual Basic 6. Working code: (Displays the artist column from a music database) Private Sub Command3_Click() Dim con As New ADODB.Connection Dim rec As New ADODB.Recordset Dim ConnStr As String Dim SQL As String ConnStr = "DSN=MusicDB" SQL = "Select artist FROM music" con.Open ConnStr, "SYSTEM", "PASSWORD" rec.Open SQL, con, adOpenStatic, adLockOptimistic Do While Not rec.EOF List1.AddItem rec.Fields("artist").Value rec.MoveNext Loop …

Member Avatar
Member Avatar
+0 forum 1

Hello, This is the first time I've attempted creating controls at runtime, and I'm not sure why the following code isn't working; private void Popup_Load(object sender, EventArgs e) { Panel panel2 = new Panel(); panel2.Size = new Size(1280, 720); panel2.Location = new Point(20, 20); panel2.BackColor = Color.Red; this.Size = new Size(1280, 720); this.Controls.Add(panel2); } I'm also trying to draw a string to the screen, but figured that wasn't working for what's probably the same reason as why the above code isn't working. Any help is appreciated, Thanks.

Member Avatar
Member Avatar
+0 forum 10

I'm trying to iterate through the controls on a form and set the tabIndex to 0 for all labels. I copped the following code from google but it doesn't work for me and I'm pretty certain it's because all of my controls are on a panel and not on the form. Does anyone know how I can modify this code to work if the controls are on a panel. I've tried lots of things with no success. Private Sub setControls() Dim cControl as control For each cControl in me.controls If (Typeof cControl is Label) then cControl.tabIndex = 0 end if …

Member Avatar
Member Avatar
+0 forum 5

How to create a form with a a button add_subjects which adds one textbox on each click, at runtime in VB and a corresponding label, 3 buttons - Add, Edit and Delete, for each textbox created. Once each texbox's corresponding Add _button is clicked, it passes textbox's value is passed to the label.

Member Avatar
Member Avatar
+0 forum 1

// A program to use a run-time loaded DLL.cpp : Defines the entry point for the console application. // #include "stdafx.h" #include <Windows.h> #include <iostream> using namespace std; //Creates a new type of variable which is a function pounter called, cryptFunPointer. typedef void (*cryptFunPointer) (int key , char inString, char outString, int length); int _tmain(int argc, _TCHAR* argv[]) { HINSTANCE hinstLib; const int SIZE = 20; char theString [SIZE]; // entered by the user char theEncryptedString [SIZE]; // after encryption char theDecryptedString [SIZE]; // after decryption – should be the same as theString cryptFunPointer encryptFunPointer, decryptFunPointer;//Declares two variables of the …

Member Avatar
Member Avatar
+0 forum 3

Hey everyone, I'm doing a practice problem and I'm stuck. The question is "Given an array a of n numbers (say doubles), consider the problem of computing the average of the first i numbers, for i ranging from 0 to n-1. That is, compute the array b of length n, where b[i] = a[0] + a[1] ....+ a[i]/(i + 1) for 0 <= i < n: Write a Java program to solve this problem. Your program can generate its own array, for example a[i] = i + 1. See how large an array you can process in less than 5 …

Member Avatar
Member Avatar
+0 forum 2

HEy guys, I got possible a stupied question but i was wondering... if you are useing microsoft runtime on all of your clients computer in a office of like 150 clients. If i put a package together with MS runtime and current databases will runtime be able to to automaticlly updated with updates like for instance when 2013 runtime comes out will it give the option to upgrade to the latest version. or will somebody have to go around and install it on every client machine. or is there a way to do this to all the clients at once. …

Member Avatar
Member Avatar
+0 forum 2

Hello, I am currently trying to develop a window form application whose content is added dynamically. What I am trying to do here is to display a number of panels with different sources across the screen horizontally. I am getting the data from a DB and depending on the number of sources (collections) through a foreach loop a number of panels is printed on screen. Only the first panel is being diplayed somehow and I cannot figure out how to show the other panels. This is my code so far: List<string> collectionName = crudObj.getCollectionNames(); _horizontalIter = 0; _panelIter = 0; …

Member Avatar
Member Avatar
+0 forum 10

hi all i am making a tabbed notepad and i have added RichTextBox At runtime.now i want to add it's sub procedural but i don't know how to add sub procedural at run time. i want to addd sub procedural with handle textchanged event. i had added follwig code for sub procedural but it's shows me error. my rutime richtexbox name is Nrt(10000). Private Sub Nrt_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) handles Nrt.TextChanged .... ....logic code.... ... End Sub **pls help me how to add sub procedural with handle textchanged **

Member Avatar
Member Avatar
+0 forum 1

Hello All, I am very new to C programming but i was working on cryptography for ipsec and am trying to write a code for implementing a simple code for a stream cipher which will take a 20 charecter long string and a 8 bit seed file and encrypt the text by performing a bit by bit xor operation on the string by generating a random number with same length as text using the seed string. I know i made some big mistakes but i dont see any compilation errors but i get a runtime error and it just prints …

Member Avatar
Member Avatar
+0 forum 2

Traceback (most recent call last): File "C:/python files/USACO/crazy/crazy.py", line 87, in <module> grid.plot(x,y,"F") File "C:/python files/USACO/crazy\grid.py", line 63, in plot self.g[(x,y)] = replace TypeError: unhashable type: 'list' You see, I'm hashing a string with the key bing a tuple. This is using my own 2d grid data structure.

Member Avatar
Member Avatar
+0 forum 3

Hi All, I would like to thank this community for the enormous help to develop my skills. Thanks. I have 2 databases and a single report form and a crystal reportviewer. The User can select the database which he want to work (Each of them belongs to different warehouse) So he can select and make dc, invoice, and associated work for the particular database. I have a dataclass it difines which database selected and which data should be retrieved using a login screen which contains a database selection combo. All goes well. I am also created a report format in …

Member Avatar
Member Avatar
+0 forum 5

hi, i am getting Run time error '13': Type mismatch error. below is my code: Dim ndMain As Node Set ndMain = TreeMain.Nodes.Add(, , "Root", "Main Menu", "myappname") thanks, krunal

Member Avatar
Member Avatar
+0 forum 4

Hi all, I was looking for a way to execute windows batch file from java code, and I was able to do this with the following code. [CODE] Runtime rt = Runtime.getRuntime(); Process proc = rt.exec("cmd /C " + "path" +exec.bat"); [/CODE] The batch file refers to some other files and executables in current directory and using relative path. Since the java program is executed from a path different from the location of the batch file, the batch program cannot find the files/executables it is referring to This leads to the batch program creating errors like [CODE]ERROR>>Could Not Find D:\xxx\Build …

Member Avatar
Member Avatar
+1 forum 5

im using jqgrid datepicker but date will show in mm/dd/yy in this format i have to change the format in runtime how i can change dis format anyone can help me

Member Avatar
Member Avatar
+0 forum 1

How can I cast a base class to a derived on at runtime. What I am trying to do is the following: I need a system which will hold the subscriptions, where a certain type of message, has an assigned Subscriber. When a message is received, it will bi forwarded to this system, which will do a lookup if there are any subscribers to this kind of message and if so, message is forwarded to subscriber. I have an abstract base class called Response, followed by an abstract layers eg. AFResponse : Response, and then there are the actual (concrete) …

Member Avatar
Member Avatar
+0 forum 1

Well, I have managed to create controls during runtime. Dim Rbut As New Button() Dim Lbut As New Button() With Rbut .Location = New Point(590, y + 15) .Text = "Remove" .Name = FontName(ListBoxCount) End With With Lbut .Location = New Point(590, y + 45) .Text = "Lock" .Name = FontName(ListBoxCount) End With Me.Panel1.Controls.Add(Rbut) Me.Panel1.Controls.Add(Lbut) AddHandler Rbut.Click, AddressOf RemButton_Click AddHandler Lbut.Click, AddressOf LocButton_Click Private Sub RemButton_Click(ByVal Sender As Object, ByVal e As System.EventArgs) ListBox1.Items.Remove(Sender.Name) End Sub Private Sub LocButton_Click(ByVal Sender As Object, ByVal e As System.EventArgs) ListBox1.SelectedItem = Sender.Name End Sub Here Rbut is Remove Button and Lbut is Lock …

Member Avatar
Member Avatar
+0 forum 12

It doesn't run! Can you help me please? Devc++ compiles it, and also launch the exe file, but it stops after the second for cycle! Why? :D [CODE]#include <iostream> #include <string> using namespace std; int main() { int N,i,z; cout<<"Digitare il umero di caratteri che contengono il nome "; cin>>N; string cod[N],nome[N]; int ch[N]; cout<<"Nome in codice "<<endl; for(i=0;i<N;i++) cin>>cod[i]; cout<<"Chiave di lettura "<<endl; for(i=0;i<N;i++) cin>>ch[i]; for (i=0;i<N;i++) nome[i+1]=cod[ch[i+1]]; cout<<endl; for (i=0;i<N;i++) cout<<nome[i]<<endl; system ("Pause"); return 0;}[/CODE]

Member Avatar
Member Avatar
+0 forum 1

Good Morning, I am this --- close to turning in a final project and my instruction states that for my asp.net vb application that we will need to turn in an executable or runtime. Since my project is .aspx I realize that an executable is not required but that I should turn in a runtime. My question? I am confused by the "turn in a runtime"? What files am I to include. I have attempted to reach my instructor but he is out of the office due to his wife's maternity leave. Guidance would be greatly appreciated. Thank you, Danielle

Member Avatar
+0 forum 0

This code is giving me runtime error. Here, first I want to take a integer input which determine the number (n) of nodes in the graph. Then for n-1 time I want take two integer input which will give the adjacency information. [CODE] #include <set> #include <map> #include <list> #include <cmath> #include <ctime> #include <deque> #include <queue> #include <stack> #include <cctype> #include <cstdio> #include <string> #include <vector> #include <cassert> #include <cstdlib> #include <cstring> #include <sstream> #include <iostream> #include <algorithm> #define MAXEDGE 1000 using namespace std; typedef struct{ int linked_to; }edg; typedef struct{ edg edge[MAXEDGE]; bool visited[MAXEDGE]; int total_nodes; }graph; int …

Member Avatar
Member Avatar
+0 forum 6

vista home premium Adobe CS5 Design Premium Acrobat X Pro Dell desktop (silvery gray):) Everything on my machines is properly licensed and registered. EVERY time I launch Acrobat X Pro I get, "MS Visual C++ Runtime Error Acrobat X/.../Acrobat.exe This app has requested Runtime to terminate it in an unusual way." It runs when I hold down shift and click the icon, but with very limited functionality. Adobe knows of the problem, its all over their forums. I've tried everything suggested there and have contacted CS, and they say the same stuff that is posted on the forums. Then they …

Member Avatar
Member Avatar
+0 forum 3

[CODE]#include <iostream> using namespace std; class bike { public: bike () { cout << "Bike: no parameters\n"; } bike (int a) { cout << "Bike: int parameter\n"; } void color(int a,int b) { cout<<"Inside Bike Color"<<endl; } }; class ducati : public bike { public: ducati (int a) { cout << "Ducati: int parameter\n\n"; } void color(int a,int b,int c) { cout<<"Inside Ducati Color"<<endl; } }; class honda : public bike { public: honda (int a) : bike (a) { cout << "honda: int parameter\n\n"; } }; int main () { ducati monster(0); ducati *dObj=new ducati(10); bike *bObj=&monster; bObj->color(10,20,30); //it's …

Member Avatar
Member Avatar
+0 forum 1

I'm trying to find degrees of separation between any two actors in a movie database. I succeed when I reach my base case, which is 1 degree of separation (i.e. actor is in same movie as another actor) but I use recursion to find all other degrees of separation, and I get "runtime error: maximum recursion depth exceeded in cmp". [CODE]##gets file with movie information f = open("filename.txt") actedWith = {} ActorList = [] movies = {} actedIn = [] dos = 1 def getDegrees(target, base, dos): for actor in actedWith[base]: if target == actor: print base, "has ", dos, …

Member Avatar
Member Avatar
+0 forum 2

Im trying to select data from a MS access database, i have done this for SQL server before with no problem, but now with a Access database i get a run time error for "No value given for one or more required parameters". Below is my code [CODE] Private Sub ViewToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ViewToolStripMenuItem.Click Dim cn As OleDbConnection Dim cmd As OleDbCommand Dim ds As New DataSet Dim dt As New DataTable Dim da As New OleDbDataAdapter Try cn = New OleDbConnection("Provider=Microsoft.ACE.OLEDB.12.0;Data Source=I:\doc_cntl\Doc_Control Lists\MS Access Logs\2009 MDL_be.accdb;Persist Security Info=False;") 'provider to be used when …

Member Avatar
Member Avatar
+0 forum 3

some commands working properly(notepad ,control(control panel))... but how to execute commands "dir" like that my code is ... [CODE] public class test1{ public static void main(String args[])throws Exception{ Runtime r= Runtime.getRuntime(); Process p1=r.exec("notepad");//working fine Process p2=r.exec("control");//working fine Process p3=r.exec("test1.java");//cannot run Process p4=r.exec("dir");// cannot run } } o/p: F:\studies\java\test>java test1 Exception in thread "main" java.io.IOException: Cannot run program "test1.java": CreateProcess error=193, %1 is not a valid Win32 application at java.lang.ProcessBuilder.start(Unknown Source) at java.lang.Runtime.exec(Unknown Source) at java.lang.Runtime.exec(Unknown Source) at java.lang.Runtime.exec(Unknown Source) at test1.main(test1.java:18) Caused by: java.io.IOException: CreateProcess error=193, %1 is not a valid Win32 application at java.lang.ProcessImpl.create(Native Method) at java.lang.ProcessImpl.<init>(Unknown Source) at …

Member Avatar
Member Avatar
+0 forum 10

As written in the title, I need your precious helps... urgently... :(

Member Avatar
Member Avatar
-1 forum 4

I have a class Node and want to declare an initially unknown number of instances of this class at run-time. First the program determines the number of nodes (num_n) from the user and then I want to define num_n objects. I have crudely got around this by defining a maximum number of nodes and storing them in a vector so they can be accessed sequentially and edited according the the user input. But, I am wondering is it possible to use a string (e.g. n1, n2, n3...), or something else, to declare these more efficiently: [CODE] include "Node.h" int main() …

Member Avatar
Member Avatar
+0 forum 5

The End.