hi there, i have a datagridview in the desktop application that i made and one of the columns in that is the telephone number. the telephone number is valid if the user type in (630) 345-2532. so everywhere the user hast to type in the paranthasis and then the numbers with a dash. is there any way i can make the datagridview column to make it display as (___) ___-____ appriciate if some one can give an guidance on this thanks

Member Avatar
Member Avatar
+0 forum 17

i'm working on visual studio 2008. I'm trying use fopen to open txt files and it does not give any errors but its not doing the required task either. i've to submit this project on monday! please help here's part of the code: [CODE]#include <stdio.h> #include<iostream> #include <conio.h> #include <string> #include <stdlib.h> #include<dos.h> using namespace std; FILE *file_ptr; node* treefromfile() { node *ptree=NULL; char word[20],meaning[100],str[120],*i; int flags=0; file_ptr=fopen("C:\Dictionary","r"); if(file_ptr==NULL) ptree=NULL; else { while(!feof(file_ptr)) { i=fgets(str,120,file_ptr); if(i==NULL) break; seperateword(str,word,meaning); if(flags==0) { ptree=maketree(word,meaning); flags=1; } else addword(ptree,word,meaning); }[/CODE]

Member Avatar
Member Avatar
+0 forum 7

I am looking to design a program in Microsoft Visual Studio 2008 in C# obviously in Windows that will read an iPhone backup folder and display some of the main contents, for example the SMS's and the call history. The main problem I face I think is interpreting the file names and being able to get to the databases because actually reading the SQLite database should be pretty easy iTunes stores the backup here \Users\USERNAME\AppData\Roaming\Apple Computer\MobileSync\Backup I know that iTunes stores the backup files with hex-encoded SHA1 hashes and I don't know how to interoperate this. For example from the …

Member Avatar
Member Avatar
+0 forum 2

I need to be able to loop and get information for up to 10 "BankAccount" arrays, but when I use less than 10 it gives me garbage and I don't know how to fix it. Here is my Code. [CODE]#include <iostream> #include <iomanip> using namespace std; class BankAccount { private: int accountNum; double accountBal; static const double annualIntRate; public: void enterAccountData(); void computeInterest(); void displayAccount(); }; //implementation section: const double BankAccount::annualIntRate = 0.03; void BankAccount::enterAccountData() { cout << setprecision(2) << fixed; cout << "Enter the account number " << endl; cin >> accountNum; while(accountNum < 1000) { cout << "Account …

Member Avatar
Member Avatar
+0 forum 8

Select a price from a ddl to populate a gridview with the items that cost the selected price or less. response.write is null at start and if there is only one item in the gridview. Else, response.write should display the amount of items and the selected price. The issue is that when a price is selected, response.write posts the correct selected price from the ddl, but the amount of rows from the gridview corresponds to the amount seen in the prior screen. If the data from the gridview is edited or sorted, it will effectively show the correct amount of …

Member Avatar
+0 forum 0

Hello, I am using a code to generate an id for a table.But it is giving 'Conversion from type dbnull to type integer is not valid' exception. Now I know that this is due to the table being an empty set.But it works properly if there is already a row in the table. How to rectify this? [CODE]Private Sub GenerateID() Dim com As New MySqlCommand If conn.State = ConnectionState.Closed Then conn.Open() End If Try com.Connection = conn com.CommandText = "select max(right(cust_id,length(cust_id)-3)) from customer" last = com.ExecuteScalar Catch ex As Exception MsgBox(ex.Message) End Try If conn.State = ConnectionState.Open Then conn.Close() End …

Member Avatar
Member Avatar
+0 forum 6

Ok, I'm not new to C++ but I am used to running a g++ compiler vs Microsoft's VS C++. I understand what this error should mean. It should mean that I'm missing a ';' on the line before or in the class Polygon. I can't seem to find anything wrong. g++ compiles the code without error. It seems like the Polygon Class isn't being loaded. Can anyone please show me what I'm missing please. I have the Application.cpp, Polygon.h, and Polygon.cpp below. Application.cpp throwing errors but if I can fix the first others will follow: application.cpp(121) : error C2143: syntax …

Member Avatar
Member Avatar
+0 forum 2

What is the problem with the following login code? [code] Dim conn As SqlCommand = New SqlCommand("Data Source=RAHUL-034890AF0\SERVER2005;Initial Catalog=user_accounts;Integrated Security=True") conn.Prepare() Dim command As Data.SqlClient.SqlCommand = New Data.SqlClient.SqlCommand("select", conn.Connection) command.Parameters(1).Value = txtusername.Text command.Parameters(2).Value = txtpass.Text Dim i As Integer = command.ExecuteNonQuery conn.BeginExecuteNonQuery() If Page.IsValid Then Response.Redirect("~/salesbill.aspx") Else Lblerror.Text = "Username and password do not match" End If conn.Dispose() [/code] I have tested the query and it works fine. The following is the error, which seems to be related to prepare statement. Im using SQL2005 and Vwd2008. The following is the error page: Object reference not set to an instance of …

Member Avatar
Member Avatar
+0 forum 3

I made a query for inserting a value from text box to MS ACCESS db [CODE] sql = "INSERT INTO Equipment (port_number,display_name,equipment,tonnage,user_privilage) VALUES (" & CLng(txtPort.Text) & ", '" & CStr(txtDisplay.Text) & "', '" & CStr(txtCA.Text) & "', " & CLng(txtTonnage.Text) & ", '" & CStr(cmbUser.Text) & "')"[/CODE] Actually I meant for inserting the data entered in the text box, but now saving is the code itself i,e; in port_number column 'CIng(txtPort.Text) ' will be saved I dont know what's the problem Please help me

Member Avatar
Member Avatar
+0 forum 3

Hello- I am trying to create a program that will allow a user to enter in checking or savings data; date, type of transaction (deposit or withdrawl), display the previous balance and the new balance based on the new transaction entered. I cannot figure out how to locate the element of the prior transaction to make the appropriate calculation. My code is quite long, and I should mention that I am brand new to this forum, so I hope I have placed my code in here properly. Thanks ahead of time. [CODE] Imports System.IO Public Class frmAccounts Dim calc As …

Member Avatar
+0 forum 0

I have a USB device (analog-digital converter) and DLL library for it (mDAQ.h, mDAQ.lib and mDAQ.dll). Can I use functions of this library in VB? How it may be done?

Member Avatar
+0 forum 0

Ive been working on a checkbook application for my visual basic class and I'm a little stumped.. To preface, the values I need to mess with include: transaction type (checking or deposit) DTP check number ("dep" if deposit) payee (who check is for) purpose of check/deposit amount of check/deposit user defined beginning account balance Below is the Change I need to make to my program... "You will create a set of either collections or arrays (your choice but use just one or the other--don't mix them) scoped at the form/module level. These structures will store all of the input data …

Member Avatar
Member Avatar
+0 forum 9

Hello everyone, I currently installed the latest version of VTK , 5.4.2, after that, I am totally lost what I have to do. Is there any well organized reference about installing vtk 5.4 on VS2008? Thank you in advance. Sungmin.

Member Avatar
Member Avatar
+0 forum 1

The End.