|
What kind of an application is that? Multi threaded or single thread? If it is a multithreaded application and if the uploading is done by a separate thread, then you will have control of that thread. If only you are using a single threaded application, Here[^] is the answer
Nobody can give you wiser advice than yourself. - Cicero
|
|
|
|
|
well sir, thank u very much... yes, i have a separate thread for uploading files and i have even written the code to abort the thread when i press the stop button.. but still not able to make it work.. well, i will again see what mistake i am doing... thank u..
vijay.
|
|
|
|
|
Hi All,
I'm having '.jpeg' and '.png' image files in my resource.
To convert then to IPicture, I'm loading the image to HGLOBAL and from it i'm creating a IStream using CreateStreamOnHGlobal() API. Till this point i'm getting the IStream pointer for both the image types.
I'm using OleLoadPicture() to convert the IStream to IPicture... this is working file for '.jpeg' images but for '.png' i'm getting the IPicture as NULL and the HRESULT value i'm getting is some negative value..
How can i convert IStream to IPicture for '.png' images...
These files are not in disk they are in my project itself as resources...
Thanx...
Do your Duty and Don't expect the Result
|
|
|
|
|
Hi,
I have to hook a toolbar to a messanger, how can i do that.
Can any one help me in this regards, plz provide me some links regarding this issue.
Thanks in Advance
Gopinath MV
|
|
|
|
|
Hi all,
I am getting a Linker Error while Running the my exe.
error LNK2001: unresolved external symbol "public: __thiscall
What i have done is i placed a macro
AFX_EXT_CLASS before the class definition to import that class.
// code
class AFX_EXT_CLASS CGTDMultiBitTrgSettingsDlg : public CGTDBasicDlg
//code
i am getting this problem what shall i do
Uday kiran
|
|
|
|
|
I think u had used static dll.
If you have import any static dll, u have to consider two main things
1. Add the lib details in project settings
2. Add the header files into exe path
And then compile.
|
|
|
|
|
uday kiran janaswamy wrote: I am getting a Linker Error while Running the my exe.
Not possible. If you have an .exe, then the linker has already been used and was successful. If the linker failed, then no .exe was produced.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
hi,
can anybody please help me on backup policy implementation?
or anybody having link of some small algorithm of backup policy like FULL,INCREMENTAL,DIFFERENTIAL backup.
Thanks & Regards
rakesh baldha
|
|
|
|
|
There are heaps of backup policies and schedules on the net. Start with googling for a policy that fits your needs.
Alcohol. The cause of, and the solution to, all of life's problems - Homer Simpson
|
|
|
|
|
Hi to all,
I am new to Visual Studios 2003, i want to develop an application in VC++.net Framework, so i have to work through the templates "Managed C++ Application", "Managed C++ ClassLibrary" and "Managed C++ Empty Project".
But In Visual Studios 2003 i didn't found any of these templates.
Can any one help me in this regard, Do i have to install them separately or do i have to check any options???
Any help or thoughts would be greatly appreciated.
Thanks in Advance.
With regards, Gopinath MV
|
|
|
|
|
The names are different but there are managed application templates in VS 2003.
in the "Add new project" dialog...
Expand "Visual C++ Projects" in the tree on the left and select ".NET"
You should see several .NET application types on the right, including the 3 you need:
Console Application (.NET) or Windows Forms Application (.NET)
Class Library (.NET)
Empty Project (.NET)
|
|
|
|
|
Hi,
I have never worked on C++ and now I have to deliver a code in next 2-3 days asap...
I have to write a code in C++ which takes an input text file from the hard disk of the following format:
D FP CDT0 "0 :400000000000:499999999999:12,13,14,15,16,17,19:10:ABCD:2:1:11101101[ab61]"
It should first check the 3rd value in each line i.e. CDT0, store it in a variable and then read the rest of the line which is : delimited. it should store these values in some array (or watever the best way to do this). Basically these values have to be copied then in the MS access DB tables. The third value of each line shows which DB table it corresponds to.
Kindly help me with your valuable inputs (code basically!!)
Thnx!
|
|
|
|
|
Only 2 or 3 days? You had better get busy then. good luck!
|
|
|
|
|
Different color
|
|
|
|
|
if I understood you want to read file,check values,enter to array and in the end insert to Access
(1) you can use of CStdioFile or CFile for read file
(2) you can use of CStrinf::Find for if values are same on each line
(3) you can use of CStringArray for insert same values
(4) you can use of CDatabase for insert to Access(you can see examples of Working with Access On codeproject)
(5) End
|
|
|
|
|
Hi whitesky,
thnx for these hints supplied!!
bt i m nt well-versed in writing code in C++. can you gimme the code for the same?
thnx a lot!
|
|
|
|
|
If you search on codeproject you can find your answer of course for each title on codeproject you can see a lot of examples.
For read of files a lot of examples.
Working with strings.
Working with databases.
I think its better you see articles because you learning many things(you are new on c++).
|
|
|
|
|
Prinky wrote: I have never worked on C++ and now I have to deliver a code in next 2-3 days asap...
Just out of curiosity, whose idea was this, and are they expecting it to work?
Are you using C++ only, or will this be an MFC application?
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
DavidCrow wrote: Just out of curiosity, whose idea was this, and are they expecting it to work?
I'm thinking job entry test
|
|
|
|
|
I think hes a student
|
|
|
|
|
WhiteSky wrote: I think hes a student
Me too...but it was much more fun imagining it as an employment interview test
|
|
|
|
|
...And also I dont think these questions for interview why?because employment question are technical,right?
if Prinky is student I hope Prinky learns c++ early.
but I think its difficult to learning c++ in a short time
|
|
|
|
|
WhiteSky wrote: ...I think its difficult to learning c++ in a short time
I agree!
"I have to write a code in C++ which takes an input text file from the hard disk of the
following format:
D FP CDT0 "0 :400000000000:499999999999:12,13,14,15,16,17,19:10:ABCD:2:1:11101101[ab61]"
It should first check the 3rd value in each line i.e. CDT0, store it in a variable and then
read the rest of the line which is : delimited. it should store these values in some array
(or watever the best way to do this). Basically these values have to be copied then in the
MS access DB tables. The third value of each line shows which DB table it corresponds to."
That's quite a project for a beginner. I think WalderMort summed it up best:
"Only 2 or 3 days? You had better get busy then. good luck!"
|
|
|
|
|
But In fact its four projects.Write to access we can set many detaily for it,read of file,for save same values he has many options I guess CStringArray is easy for Prinky
|
|
|
|
|
Problem Description
My project (Testing) is CFormView based SDI application. On the form view, there is a CEdit control (IDC_EDIT_ExampleText). It is used to display the full path of a selected file. Sometimes, a long path may go beyond the boundary of the CEdit control.
So, I would like to use a Tool tip to display the long path.
I implemented the tool tip functionality for the CEdit control by the following steps. However,
two tip windows poped up one after the other containing the same contents whenever I moved the cursor on to the CEdit control.
another question is when I change
ON_NOTIFY_EX(TTN_NEEDTEXT, 0, SetTipText)
to
ON_NOTIFY_EX(TTN_NEEDTEXT, IDC_EDIT_ExampleText, SetTipText)
the tool tip does not pop up any more. Why, it should be '0'.
--------- Steps --------------
Step 1: declare a CToolTipCtrl member variable for CTestingView
CToolTipCtrl *m_ToolTip
Step 2:
in the OnInitialUpdate(), add the following lines
<br />
EnableToolTips(TRUE); <br />
m_ToolTip= new CToolTipCtrl();<br />
m_ToolTip->Create(this);<br />
<br />
m_ToolTip->AddTool(&m_EDIT_ExampleText, LPSTR_TEXTCALLBACK);<br />
m_ToolTip->Activate(TRUE);<br />
<br />
Step 3:
Overload the function PreTranslateMessage by adding a new member function PreTranslateMessage(MSG* pMsg) to CTestingView
<br />
<br />
BOOL CTestingView::PreTranslateMessage(MSG* pMsg)<br />
{<br />
if(m_ToolTip != NULL)<br />
m_ToolTip->RelayEvent(pMsg);<br />
<br />
return CFormView::PreTranslateMessage(pMsg);<br />
<br />
<br />
}<br />
Step 4:
Add messae mapping
<br />
ON_NOTIFY_EX(TTN_NEEDTEXT, 0, SetTipText)<br />
<br />
Step 5:
Add new member function SetTipText(UINT id, NMHDR *pTTTStruct, LRESULT *pResult) to CTestingView
<br />
BOOL CTestingView::SetTipText(UINT id, NMHDR *pTTTStruct, LRESULT *pResult)<br />
{<br />
TOOLTIPTEXT *pTTT = (TOOLTIPTEXT *)pTTTStruct;<br />
UINT nID = pTTTStruct->idFrom;<br />
nID = ::GetDlgCtrlID((HWND)nID);<br />
char * Content_m_EDIT_ExampleText;<br />
Content_m_EDIT_ExampleText = (char *)malloc(sizeof(char) * (m_EDIT_ExampleText.LineLength() + 2) );<br />
m_EDIT_ExampleText.GetLine(0, Content_m_EDIT_ExampleText);<br />
strcpy(pTTT->lpszText, "ooppp");
<br />
<br />
<br />
return (FALSE);<br />
}<br />
<br />
|
|
|
|