|
Did you import lib file?
Of one Essence is the human race
thus has Creation put the base
One Limb impacted is sufficient
For all Others to feel the Mace
(Saadi )
|
|
|
|
|
I have only imported to cximage.lib file.
As rest of the library files to include i cant find.
I am downloading the linked library files from http://www.xdp.it/cximage/
But after unzipping the files i cant seem to find the ".lib" file of each of the linked libraries
Do i need to compile the downloaded projects if so with what settings
I am using Visual Studio 2008
Thanks
|
|
|
|
|
I have five records in 2D array (w/ pairs, X and y coordinates).
Wants to search position [records already sorted according to y ] and insert weighted number and leave the 2D array sorted.
Please help............
Thanks
|
|
|
|
|
Please elaborate.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
Dear all
i am new in C++ but old in VB and other softwares my problem is i need to create a DLL which will browse for the folder and select a file i have surf the net but could not find a single solution for the same except i found some file which is nearby what i wanted but it creates and EXE and i wanted a DLL
i need sepecific things which will open the browse folder as soon i call the DLL and return the filename after it browse
Kindly help please
Sanjay Jobanputra
|
|
|
|
|
To create a DLL project, go to the "File" menu, select "New Project" and then "Class Library" - that will generate a DLL instead of an exe.
I'm not sure I really understand what you want the DLL to do but it sounds like a file open dialog, which you don't really need to have as a separate DLL unless it's going to do some other things with the file.
There are three kinds of people in the world - those who can count and those who can't...
|
|
|
|
|
To expand on molesworth's answer, Win32 provides GetOpenFileName[^] (let the user select a file/files) and SHBrowseForFolder[^] (let the user select a folder).
Both are usable from VB6, if htat's what you need:
SHBrowseForFolder[^]
GetOpenFileName[^] - this example's VB5(!), but VB6 and VB5 are similar enough...
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
I think you dont need to make a dll for it you can use of these apis on VB(Stuart Dootson' answer).
Of one Essence is the human race
thus has Creation put the base
One Limb impacted is sufficient
For all Others to feel the Mace
(Saadi )
|
|
|
|
|
Any specific reason for creating dll, when you achive same by simply writing a function in your application?
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow Never mind - my own stupidity is the source of every "problem" - Mixture
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and You
|
|
|
|
|
Dear All
Thanks but my problems is different
A) I am not expert in C++
B) The software which we use calls only C++
C) i have checked the net where i found similar things but it creats only an exe whereas i wanted on DLL
What DLL i wanted is as soon i call the class it will open an opendialog like how it happend in windows the -->file->>open--> selcect the file -->>
Thanks in Advance
|
|
|
|
|
Can someone direct me to an article if this is possible.
I have 3 interloops in a process that takes about an hour or so to complete, based on the data it seems to be right.
However I have that process in it's own worker thread. I was wondering if that can be further multithreaded?
|
|
|
|
|
As you've mentioned a 'for' loop, I think OpenMP[^] is probably the simplest first thing to investigate, as it's aimed at that sort of thing[^].
Here's a CP article[^]...
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
FISH786 wrote: However I have that process in it's own worker thread. I was wondering if that can be further multithreaded?
Yes and No!, answer is based on software design, your company software architect can help in this case. It very difficult to answer this question from remote.
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow Never mind - my own stupidity is the source of every "problem" - Mixture
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and You
|
|
|
|
|
hi,
i want to simulate a key press on a window.
eg: ive handle to the notepad window and i want perform "ctrl+s" on notepad.
how to do that, please help me
Thanks & Regards
|
|
|
|
|
|
I am deleting a record from the table and then using the MoveNext()fucntion to move to the next record in the recordset.Below is the code for that.
How do i do that using the code below ??
<pre>void CSimpdbView::OnRecordsDelete()
{
CSimpdbDoc* pDoc=GetDocument();
_CommandPtr pCmd;
pCmd.CreateInstance(__uuidof(Command));
_ParameterPtr paramIsbn;
CString strIsbn;
CEdit* pEdit = (CEdit*)GetDlgItem(IDC_ISBN);
pEdit->GetWindowText(strIsbn);
_bstr_t sqlQuery("DELETE FROM lib WHERE ISBN = ?");
int val = MessageBox("This deletes the record.Continue ?",NULL,MB_OKCANCEL);
if(val == IDOK)
{
try
{
pCmd->ActiveConnection = pDoc->m_pConnection;
pCmd->CommandText=sqlQuery;
paramIsbn = pCmd->CreateParameter("strIsbn",adVarChar,adParamInput,-1,vtMissing);
paramIsbn->Value = (_variant_t)strIsbn;
pCmd->Parameters->Append(paramIsbn);
pCmd->Execute(NULL,NULL,adCmdText);
MessageBox("Record Deleted !",NULL,MB_OK);
pRs->MoveNext(); //Should move to the next reccord !
}
catch(_com_error &e)
{
TRACE( "Error:%08lx.\n", e.Error());
TRACE( "ErrorMessage:%s.\n", e.ErrorMessage());
TRACE( "Source:%s.\n", (LPCTSTR) _bstr_t(e.Source()));
TRACE( "Description:%s.\n", (LPCTSTR)_bstr_t(e.Description()));
}
catch(...)
{
TRACE("\n****Unhandled Exception****\n");
}
}
}
Help Please .
|
|
|
|
|
What's wrong with the recordset's Delete method[^]? (Well, possibly this[^], it's something you need to check).
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
OMG!! I m sorry i forgot to add the question to the post!!
Well, in the above code i m able to delete the record but i want it to show the next record once the record is deleted.For which i m using the pRs->MoveNext() method.
What i want to know is how do i do this ??
|
|
|
|
|
I think using the Delete method of the Recordset allows you to do just that without needing to worry about delete commands or anything like that. I guess you just need to open the recordset as read-write? This page[^] may provide more reassurance about that.
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
But isnt there a way where i could delete the record using sql query and then move to the next record and show it on GUI ?
|
|
|
|
|
I've just looked at your code properly - I presume pRS is a member of a class somewhere whose cursor points at the current record that a) you're displaying, and b) you want to delete?
If so, then this should work:
void CSimpdbView::OnRecordsDelete()
{
int val = MessageBox("This deletes the record.Continue ?",NULL,MB_OKCANCEL);
if(val == IDOK)
{
try
{
pRs->Delete(adAffectCurrent);
MessageBox("Record Deleted !",NULL,MB_OK);
pRs->MoveNext();
}
catch(_com_error &e)
{
TRACE( "Error:%08lx.\n", e.Error());
TRACE( "ErrorMessage:%s.\n", e.ErrorMessage());
TRACE( "Source:%s.\n", (LPCTSTR) _bstr_t(e.Source()));
TRACE( "Description:%s.\n", (LPCTSTR)_bstr_t(e.Description()));
}
catch(...)
{
TRACE("\n****Unhandled Exception****\n");
}
}
}
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
In my code i deleted the record using sql query as you can see,and i have declared :
ResultsetPtr pRs;
in the View.h file.So it is globally accessible.So in that case (making changes to the code you gave),i have to call the sql query
select * from lib_details where ISBN = ? ;
and then insert the parameter using command object and append function
and then call pRs->Open()
and then pRs->Delete(adAffectCurrent);
and then pRs->MoveNext(); //as you have mentioned in your code
I hope what i have mentioned is right.
But instead of this can i delete the record using sql query and then move to the next record ? if this is possible how can it be done ? and i guess it would be easier .
|
|
|
|
|
vital_parsley2000 wrote: But instead of this can i delete the record using sql query and then move to the next record ?
The term 'next record' has no meaning unless you've selected a bunch of records into a recordset. What I thought you had done (and would suggest you do) is select the records you are interested in (using a SELECT statement) into a record-set. Then the user can delete a record if they choose to (using the record-set's delete method, as I showed you) and you can move on to the record-set's next record. The record-set would be declared at class scope, so it is persistent across event handlers. Something like this (obviously this is a bare-bones sketch of what you'd use):
class MyDoc
{
_RecordsetPtr pRs;
void SelectRecords(parameters) { }
};
class MyView
{
void DisplayRecord() {
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
|
If the objcore.cpp in your MFC is like mine, you've got a bad object somewhere. Look at a) what the assertion in objcore say, b) which of your objects it is acting on, c) the call stack - that will show where in your program the assertion originates.
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|