Originally posted by: Ofir
here is a part of my source:
void CMainFrame::OnFilterNew() //IP missing
recordset.Open(AFX_DAO_USE_DEFAULT_TYPE,
recordset.AddNew();
I have an existing file of database named DataBase.mdb,
the problem is that when i tryed to open the dialog box
"NewFilter" it gives me the following message: "Unrecognized database format E:\DataBase.mdb"
{
CDaoDatabase database;
CDaoRecordset recordset(&database);
CString lpszFile = "E:\\DataBase.mdb";
database.Open(lpszFile);
CString s="/";
int a;
//CGuiSet rs ( NULL );
NewFilter MyDlg;
MyDlg.DoModal();
//IP=MyDlg.m_IP;
Protocol = MyDlg.m_Protocol;
Text = MyDlg.m_Text;
Start = MyDlg.m_Start;
Alarm= MyDlg.m_Alarm;
End = MyDlg.m_End;
"SELECT * FROM MyTable", 0);
database.Execute("INSERT INTO Filter(Filter);");
//database.Execute("INSERT INTO MyTable(Age);");
recordset.SetFieldValue("Filter","Chris");
//recordset.SetFieldValue("Age","None");
recordset.Update();
recordset.MoveNext();
recordset.AddNew();
recordset.SetFieldValue("Filter","Joe");
recordset.SetFieldValue("AlarmFilter","20");
recordset.Update();
}
Reply
Originally posted by: zeinalzadeh
Dear Sir
How the data of combobox can be valued by code. While we exit from program that data be saved in data properties.
Originally posted by: zeinalzadeh
Dear Sir,
How we can define format of a time field in
command of create table. we want format of field Date_List
be "short time".for example in bellow code:
db.Create("listdate");
CString Sq1Cmd = "CREATE TABLE listdate(Date_List time)";
db.Execute(Sq1Cmd);
Thanks in advance,
ReplyOriginally posted by: ashkan
Dear Sir
How can write time of system in a field of a DAO.
SYSTEMTIME sysTime; // Win32 time information
GetSystemTime(&sysTime);
COleDateTime time5(sysTime);
CString date1=time5.Format(" %A %B %d,%Y");
How can define time field and write date1 value in that field.
sincerely yours,
Originally posted by: None
Hi. I have a simple question. How do I get the program running? I can open the .cpp files in C++ builder 5, but when I hit the run button I get the message "debugger kernel BORDBK51.dll missing or not registered". I'd like to see the program as a usual c++ builder project with all files included (project files, and so on).
Thanks alot.
ReplyOriginally posted by: ashkan
Dear Sir
How can write date of system in a field of a DAO.
How can define date field and write date value in that field.
sincerely yours,
Originally posted by: umesh
hi
I want to exract the certain things using SQL statements
can any body help me???
Iam using Microsoft access 2000
my query is
price Condition vaule
----- -------- -----
1000 < 200
102 > 1200
3000 = 3000
4000 >= 1000
I want to Extract the PRICE depending on Condition.
i.e if the Value is <(condition) 1000 then Price value should disply(etract) else not.similarly for all the conditions
so please help me
umesh
Reply
Originally posted by: Eric Sanders
Having failed to come up with a method to change the attributes of the database, I came up with an easy solution. I first create a database with Access, setting everything the way I want it, then I add the empty database as a binary resource to my app. When the user select File|Create New Database, I simply open the resouce, and write it to disk. I'd still like to find a way to change the attributes on the fly however!
Regards,
Eric Sanders
www.compufoil.com
Originally posted by: Newbie
This is great I was looking for an easy way to do this .... MSDN was totally not a help with its complicated look on it. I been searching for about 1 hour and I found this .... INCREDIBLE!
Reply
Originally posted by: Pham Ngoc Nam
I have tried create database but I don't known how to create a field with type is AutoNumber like MS Access.
Please tell me soon
thanks