199,114 Archived Topics
Remove Filter ![]() | |
Hello, I am trying to write a simple javascript to read all forms. My ReadForm function works right. I tried it out of ReadAllForms function, there is no problem with it. I think document.getElementsByTagName returns false. Why can this happen? [CODE=javascript] function ReadAllForms() { if (document.getElementsByTagName) var myforms = document.getElementsByTagName("form"); … | |
wondering if there is a way to shorten up this IF statement i have going on.. [code] If my.settings.id <> 1.001 or my.settings.id <> 2.001 or my.settings.id <> 3.001 then do it like this end if [/code] what im looking for is a shorter way, i have tried [code] if … | |
i m newbie in web development plz help me to sort out the problem.. the problem is: in [B][U]edit.php[/U][/B] when control enters in if condition it never goes to else when i press the edit button. i want to get id from view.php and display category name in edit.php textbox … | |
Hey, i hav asp pages n wen i browse dis asp pages through IIS it gives d "Server Application Error" I m nt able to understand wats d problem. The error is: Server Application Error The server has encountered an error while loading an application during the processing of your … | |
IE tells me there's an error on line 17, which is the onload method of the body tag. So here's the code... [code] <script language="javascript" type="application/javascript"> function startUp() { setFocus(); } function setFocus(){ document.frmSearch.txtSearch.focus(); document.frmSearch.txtSearch.select(); } </script> [/code] And here's how it's called: [code] <body onload="startUp();"> [/code] I tested this … | |
Hello. I am new to c sharp . I want to know how to store image in access database. And retrieve back to picturebox . Which data type is used to store image..? Plz help..... | |
Hi. I create the table (MS SQL 2008) IdUrovniaKatHerakl - HierarchyId (not null primary key), KatName nvarchar(max) not null, LevelKat as RowId.GetLevel() KatId - int KatOpisanie nvarchar(max) How can I using C# in Visual Studio 2010 (RC) insert new data into this table? I do this: create DataSet and Create … | |
I'm basically trying to alter the font size for my program in accordance with the resolution; the programming itself is fine, it's more the maths of it which is the problem. For example: 800x600 - physical font height = 22 1024x768 - physical font height = 22 etc etc. As … | |
I get this when i click on the done button in my program: [CODE]Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException at BillPanel.getTotalPrice(BillPanel.java:49) at BillPanel$ButtonListener.actionPerformed(BillPanel.java:62) at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1995) at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2318) at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:387) at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242) at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:236) at java.awt.Component.processMouseEvent(Component.java:6038) at javax.swing.JComponent.processMouseEvent(JComponent.java:3265) at java.awt.Component.processEvent(Component.java:5803) at java.awt.Container.processEvent(Container.java:2058) at java.awt.Component.dispatchEventImpl(Component.java:4410) at java.awt.Container.dispatchEventImpl(Container.java:2116) at java.awt.Component.dispatchEvent(Component.java:4240) at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4322) at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3986) … | |
I made this really strange and not working code just to count the total number of letters in a string(user inputs then stops with enter), as well as divide each individual character(a, b, c etc) by the total number and show that as well. The reasoning seems right but can … | |
Here is my current situation. I have a global array and it is originally declared as an int pointer. I malloc (100*sizeof(int)) to this pointer in the main method. I then use this array to store values and these values are assigned inside of two for loops. The problem is … | |
I have a dataGridView with 4 columns. 3 of the columns i want to use a combobox. In the datagridview properties from the design view i already set the columns to DataGridViewComboBoxColumns. how do i from the code set the columns values from a dataset? I can get the data … | |
so heres a snippet of my code: [CODE] cout << "enter keyphrase: \n"; cin >> nextchar; while(nextchar != '.') { isalreadyin = 0; for (int i=0; i<counter; i++) { if (key[i] == nextchar) isalreadyin = 1; } if(isalreadyin ==0) { key[counter]=nextchar; counter ++; } cin >> nextchar; } [/CODE] at … | |
Hi, I needed some help on how to add Validation on text boxes. I wanted validation such as only adding numbers, or max 7 characters for postcode, etc. I wanted a validation on postcode so that if the correct format doesn't appear (ex, LE5 7LD) then a message box would … | |
K...so this is an airline reservation program I have been working on for school and I can't see where I am going wrong. Basic functions of this would be taking reservations for either first class or economy class seating on a 10 passanger plane. seats 1-5 are supposed to be … | |
Hi, I need a C# code to retrieve the URL address from a web page like [URL="http://www.protect-url.com/?u=p0xjz178380czht6"]http://www.protect-url.com/?u=p0xjz178380czht6[/URL] It seems the link is here [URL="http://www.protect-url.com/go.php?l=p0xjz178380czht6"]http://www.protect-url.com/go.php?l=p0xjz178380czht6[/URL] and we need to call url.php Can you help me please? | |
Hi All, I am trying to add a an element(Select Box and added a function in onChange) through Javascript, which is working fine in IE6, IE7, FF and Opera. But i am failing in IE8. If anyone has come accross this issue please help me. here is my code [code=javascript] … | |
Hi guys, I have written a simple script to get a bunch of lines from a text file (they will be filenames eventually) which are split by new lines and puts each one into an array.. [CODE] Dim ary() As String Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As … | |
i m newbie in web development plz help me to sort out the problem.. the problem is: in [B][U]edit.php[/U][/B] when control enters in if condition it never goes to else when i press the edit button. i want to get id from view.php and display category name in edit.php textbox … ![]() | |
I have found a module pycrypto which has an AES encryption and decryption function, in commandline everything works fine both encryption and decryption, but if I want to implement it in my program, it fails =( [code=python]def aes(txt): global crypt message="".join(txt) #format the message which has to be encrypted/decrypted to … | |
The following function converts a positive decimal number to base 8 and displays the result. [code=c++] void displayOctal (int n) { if (n > 0) { if (n/8 >0) displayOctal(n/8); cout << n%8; } //end if } //end displayOctal [/code] I have to trace the function with n = 100. … | |
hi...i am worjig on project to display numbers entered by user..and display it in random order....i use devcpp.. and here is the code..it does compile but is not working properly..can anyone help me plz as quickly as possible..this is due within 4 days... [CODE]#include<iostream> using namespace std; int main(){ int … | |
Write a Java program that will generate random four letter words. The words must consist of only lower case letters. The program will prompt the user to enter the number of words to generate. The program should request that the user enter a number between 1 and 500 and ensure … | |
Hi! I have a program with two QSpinBoxes with integers in them. When user clicks one spinbox it should affect to the other one. And vice versa. I can't use valueChanged() signal because it causes an endless loop that won't stop until the maximum values of the boxes have been … | |
Can someone take a look at the code to see where is the mistake because i can't display the 10 records of my database per page [CODE] <% Option Explicit ' ADO constants used in this page Const adOpenForwardOnly = 0 Const adLockReadOnly = 1 Const adCmdTableDirect = &H0200 Const … | |
Hi all, I'm just learning C# and completed a book exercise. They had a different answer and I'm not sure the difference between the two. The way I did a method was like this: [CODE]public int ShiftsLeft { return shiftsToWork - shiftsWorked; }[/CODE] However, when I looked at the book … | |
I want my code to take two characters and print them, but this code only takes one character, prints it and terminates, can you please tell me what's wrong with it? Thank you. [code=syntax] #include <stdio.h> int main() { char a, b; scanf("%c", &a); scanf("%c", &b); printf("%c %c\n", a,b); return … | |
Trying to figure out why code wont work. Its gets 2 errors for String newS1 = s1.sort; String newS2 = s2.sort; I dont know how know whats wrong [CODE]public class anagram { public static void main(String args[]) { java.util.Scanner input = new java.util.Scanner(System.in); System.out.print("Enter the first string: "); String first … | |
Hi All, Below are two files, one being the index page, and one being the functions page. My problem is when i use a function it just gives me a blank screen. The echo at the top of the index page is simply a sanity check. Do i have an … | |
hello all, i want to question how to i get value query sql in asp.net c# example: this is my sample code: [CODE] string no_hp = ""; string queryNoHP = "SELECT NO_HP FROM REF_OWNER WHERE ID = '" + ID.Text + "'"; [/CODE] i want to how to get value … | |
I am very new to this and trying to call a method which will update the record depending on the check box user clicks. now my jsp looks like this [CODE] <input TYPE="checkbox" name="<%=as.getAppId()%>" id="<%=as.getAppId()%>" <%=((as.isStatus()==true)?"CHECKED":"")%> onClick="update('<%=as.getAppId()%>')" /> [/CODE] and the scripts [CODE] function update(appId) { var stat = eval("document.getElementById(appId)"); … | |
Help With Add, Delete, Edit and Update Record (with Datatable Method) I Created a Software with OleDb .mdb database previously Using Dataset Method, but I was unable to Connect Datagrid with it on real Basis, I mean when I Clicked Next Record Button it only Moves in TextBoxes (Which were … | |
hi friends, From many days I wanted to create some application in Windows. Now which IDE would be better (I am also a bit confused with the term IDE ) Turbo c or Borland C++ bulder or Visual c Whatz the difference between these things?? Please someone clear my confusion. … | |
[QUOTE]$tag = $_GET[tag]; $search = mysql_query("SELECT * FROM `threads` WHERE FIND_IN_SET('$tag', `tag`) = '$tag'"); [/QUOTE]why is this returning all of the rows in the table they all do not have the same tags none of them have the same tags as each other yet the column name is tag. the … | |
I am trying to teach myself C#. I was working on an example when I came across something of interest (to me anyway), and none of my resource material explains why this happens. Can some one explain why this happens. The code below works as it should [CODE] //calc test … | |
[CODE]#include <iostream.h> #include <stdlib.h> #include <conio.h> #include <iomanip.h> #define FALSE 0 #define TRUE 1 float table_req(void); //Gets Multiplication Number int lines_req(const float); //Gets number of lines void print_out(const int, const float); //Print out of Table int quit(void); //Check Continue request y/n float input_number(void); void main() { int exit = FALSE; … | |
I am trying to complete an assignment in C#. I have buttons for name, address and zip code. I have Buttons for Display Label Info, Clear and Exit. I can type whatever I want into the form and I can clear them and exit with them. My problem is with … | |
Hi people need codes for displaying serial number in a receipt (ie a unique number after every transaction) here is the receipt code am working on [code] Private Sub CmdPrint_Click() 'printing a receipt If MsgBox("Print Receipt?", vbYesNo, "Receipt") = vbYes Then Printer.Print Tab(30); Printer.Print Tab(30); "TIKMASH MANAGEMENT LIMITED" Printer.Print Tab(30); … | |
Account.java [CODE=java] package btclass; import java.util.Scanner; public class Account { private float amount;//actual amount private static float balance;//balance amout Scanner keyboard = new Scanner(System.in); public void deposit() { System.out.println("Enter the amount you want to deposit: "); float depos = keyboard.nextFloat(); if (depos < 0) { System.out.println("Amount you entered is < … | |
I have implemented Google search in my web application. It is asking for license key.... where i should sign up... how to get license key? Plz its very urgent Plz do reply | |
How do I exchange data from page to page? for example: on the 1st page I voted for 1 person, when I click submit it will go to the 2nd page that will let you see the output of the vote? I can't seem to do it, as I don't … | |
I have a program which connects to a remote MySQL Server. When i try running the program on other PCs (ones with nothing more than the .NET Framework) I tried using ODBC, which would run the program, but not be able to connect to the database because of the lack … | |
When this program prompts the user for input, it works fine for the correct input. But for the wrong inputs, it returns a zero for every character, including the white spaces. My goal of this program is to return a roman numeral as an integer. For the wrong inputs, I … | |
I'm trying to get this program to ignore leading tabs and blanks, but I just can't seem to figure out how. What can I further do to improve this program? [CODE]/* Read a command, skipping over leading blanks and any trailing * characters. */ #include <stdio.h> /* Declare functions */ … | |
hey can anyone help this is the code i have. i need to ouput the even and odd integers between two integers. i think what i have might work but when i run it it keeps running and never stops. also first num needs to be less then second anyone … | |
Hello. I want to find numbers lies in between (x, y) and [x, y]. I Googled for this and saw that it can be done using boost library. But I can not understand the synopsis. Please help me. | |
im building a clone youtube site and the templates have smarty code every-time i try to add a style to it or even change the bg color of the template i get this error. could someone show me an example on what im supposed to do. and how it should … | |
Hello everyone, i 'built' a simple windows forms application, with 2 buttons and 1 picturebox. One button is used for invoking an open file dialog, which prompts for a BMP from the harddisk, which is inserted on the picturebox. The other button should do 'stuff' to the image, in a … | |
Hello, I just only want to ask.How to connect MS access database to a C program.See the code below: #include<stdio.h> char firstname[20], middlename, lastname[20]; main() { clrscr(); printf("Enter your First Name: ");scanf("%s",&firstname); printf("Enter your Middle Name: ");scanf("%c",&middlename); printf("Enter your Last Name: ");scanf("%s",&lastname); getch(); } This is what I want to … |
The End.