|
Have you bothered to step through your code using the debugger to see where the problem lies?
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Thanks for suggestions
I've stepped into it, and find something seems wrong at
if(pBuf)
{
rgsabound[0].lLbound = 0;
rgsabound[0].cElements = nFileLen;
psa = SafeArrayCreate(VT_UI1, 1, rgsabound);
for (long i = 0; i < nFileLen; i++)
SafeArrayPutElement (psa, &i, pBuf++);
varBLOB.vt = VT_ARRAY | VT_UI1;
varBLOB.parray = psa;
m_pRecordset->GetFields()->GetItem("mol")->AppendChunk(varBLOB);
}
becouse when i did as follow:
m_pRecordset->Update();
long lDataSize = m_pRecordset->GetFields()->GetItem("mol")->ActualSize;
I find that the value of lDataSize is alwayse -1
do you know the reason, please?
thanks a lot
regards.
Li
Hi, there.
|
|
|
|
|
I've also posted my question in the ADO forum,
http://www.codeproject.com/script/comments/forums.asp?forumid=1725&select=2047403&msg=2047403
so, please go there if you want to help me, thanks.
best regards
Hi, there.
|
|
|
|
|
hi,
How can i read data from an excel file and write data to the cells, by just specifying the column name? how to open and close the excel file?
Thanks in advance.
SYAMLAL
|
|
|
|
|
Search for Excel Automation.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
|
|
Hello,
In VC++6 you can go to project settings and in th LINK tab, set the names for the object/library modules.
How can this be done in VC++8?
Thank you in advance.
|
|
|
|
|
Project -> Properties then expand Configuration Properties then Linker then click on Input. Add your libraries to Additional Dependencies
Judy
|
|
|
|
|
Go into project properties, "Linker", "Input" and put them in "Additional Depedencies".
|
|
|
|
|
hai,
i want to store the userdefined values in a dialog based applications & i want to get that values when we run the program next time.
|
|
|
|
|
You can save the data to a file and then load the file when your program start the next time.
|
|
|
|
|
If you are using MFC, then have also a look at Serialization [^].
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.
|
|
|
|
|
jannathali wrote: userdefined values
What kind of values is this about?
Perhaps you should consider using the registry if this is about application settings.
"It's supposed to be hard, otherwise anybody could do it!" - selfquote "High speed never compensates for wrong direction!" - unknown
|
|
|
|
|
|
Problem- When I click on the empty space after any item or after all items then the current item selection goes away and I have no way to highlight previous item. (Though I have pervious selected item index).
This is beacuse when item is selected MFC gives us two messages
1. Pervious Item Deselected.
2. Current item Selected.
But when we click on empty area then
1) it gives message - Item Deselected ...
and there is no other message again ....
So we cant track whether you get 1 or 2 message from MFC....
This is all my perception about CListCtrl behaviour
Does any one have a way to this problem????
Thanks in Advance
AmolM
|
|
|
|
|
You can catch the OnSelChangeListCtrl(...) and always keep the index of the previously selected item. Once you get that there is no selected item (when clicking under the last item) just call
ListCtrl.SetItemState(PrevSelItem, LVIS_SELECTED, LVIS_SELECTED);
|
|
|
|
|
Sorry, but I didnt find any message like OnSelChangeListCtrl() for CListCtrl.
I have captured
1) OnItemchangedList1() and
2) OnItemchangingList1()
And the scenario was like the problem I posted....
I just can get the item selected or not
Sequence of message is like
1) Previous item de-selected and
2) Current Item Selected ==> in case item is selected...
Otherwise
only 1st message.... if item is not selected (Clicked on empty area)
Any Commments on this...
Thanks for previous reply
Thanks in Advance
AmolM
|
|
|
|
|
Aamol M wrote: 1) OnItemchangedList1() and
Which is what GuyM was referring to as OnSelChangeListCtrl() . Whatever you are calling it, when the LVN_ITEMCHANGED notification is received, look at the uNewState member to see if it is LVNI_SELECTED . If so, save the item's value.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Hi all.
I have problem new create process.
I must set paramets in command line wen I create process.
and I dont know, how to do this.
can help?
|
|
|
|
|
david bagaturia wrote: I must set paramets in command line wen I create process.
and I dont know, how to do this.
That's what the second argument is for.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Hi all.
I have problem new create process.
I must set paramets in command line wen I create process.
and I dont know, how to do this.
can help?
|
|
|
|
|
Try the following:
CString strExeAndParams = _T("\"C:\\MyExe.exe\" Param1 Param2");
BOOL bOK = CreateProcess(NULL, (TCHAR*)(LPCTSTR)strExeAndParams, ...);
Note that the path to the executable is wrapped with \" - because if the path has as space in it (like in "Program Files"), Windows will interpret the first half as the EXE name and the second half as the first command-line parameter.
Hope this helps ...
|
|
|
|
|
|
How can I make title bar disappear from MDI Frame?
Thanx In Advance
Z.A
|
|
|
|