|
Do not waste your time on things like the C-RTL and Win32 functions (SetEnvironmentVariable(...) ) to set environment variables - these only affect the process' environment space - other processes will not be affected, nor will you see the change when you bring up up the system properties.
If you need to change these values such that the change remains after your application exists and/or are visible to other application and the system, you will need to modify the registry.
Look up the HKCU\Environment and HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Environment registry keys for more information on how to do this.
Peace!
-=- James If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong! Avoid driving a vehicle taller than you and remember that Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road! DeleteFXPFiles & CheckFavorites (Please rate this post!)
|
|
|
|
|
Thanks for your valuable information
|
|
|
|
|
Hi!
I've got small (I hope) problem.
I'm using some video player. It has almost all that I need - I miss only one thing in it. It can't made screenshots (no ability to save one frame of played video to image file).
I created graph file with SampleGrabber for this video player, but the problem is how to use SampleGrabber when it is working with other application and create screenshot from Video that actually is played? Video finally goes to VMR9...
Or maybe there's other way to get screenshot from video played in VMR9 in other player... but how?
Greets
|
|
|
|
|
You'd need to be able to communicate with the other player somehow. How do you know the other
player is using DirectShow?
|
|
|
|
|
in an MFC Appl with DB without file support i've a two field (Database in Access) in Table Password -- [User] n [Pass].
The hint box in the m_pSet variable is showing the variable but on tryin to retrieve th data( i'v three records in the table) only "" is returned .
what can be the error. I don't want to use m_pSet->m_strSort rather in the m_pSet->Open(...) i'm pumping the exact query.
what can b the error.
a snippet of the whole code is
<code>Pass p1;
p1.DoModal();
CString str,query,str1;
int flag = 0;
str=p1.m_pass;
m_pSet->Close();
query = "Select * from Password where User='Admin'";
m_pSet->Open(CRecordset::dynaset, (LPCTSTR)query,CRecordset::none);
m_pSet->MoveFirst();
MessageBox(m_pSet->m_Pass.GetBuffer(20));
while(!m_pSet->IsEOF())
{
str1=m_pSet->m_Pass.GetBuffer(20);
if(str1==str)
{
flag=1;
break;
}
m_pSet->MoveNext();
}</code>
actually i've to retriev user n pass from a popup dlg n then verify it from the DB.
here to check i've used default user as Admin.
what can b the error.
plz help
-- modified at 1:37 Thursday 28th December, 2006
Shouvik
|
|
|
|
|
Are you getting any value in the Message Box? I think the problem with GetBuffer menthod. you need to convert it to CString, because the return type of GetBuffer method is LPTSTR.
Subbarao.
|
|
|
|
|
Actually there was a field name mismatch yesterday. So on rectifyin it the appl is working. no need to cast it to LPCTSTR as an overloaded method already is avail.
thanks a lot.
Shouvik
|
|
|
|
|
shouvik.d wrote: m_pSet->m_Pass.GetBuffer(20
Try using CRecordset::GetFieldValue instead.
|
|
|
|
|
Sorry to all,
but i solved the prob. Thanks
Shouvik
|
|
|
|
|
It will be helpful to other, if you post how you'd solved it.
|
|
|
|
|
yes i thought that and replied to Subbarao. It's just a mismatch in the fieldnames defined in C<<proj_Name>>View.cpp n the one existing in the DB. U pointed out the solution to me yesterday.
but strange thing was that the m_pSet->m_Pass was only thing not getting retrieved whereas all other values from table(s)(even other tables) were showing up.
What do u think could be the reason
-- modified at 2:38 Thursday 28th December, 2006
Shouvik
|
|
|
|
|
Again, there might be mismatch in field names. Have you tried using GetFieldValue .
But, you solved your prblem, isn't it?
|
|
|
|
|
no not anymore. had there been the prob existin still now there would ve been a Too few parameters. Expected 1. would've been the message again. all fields are set right so its working fine now.
Shouvik
|
|
|
|
|
hi ,
i am looking for sample programs on tree view control with check boxes. if any body having could u plz send it to sramesh21@gmail.com.
thanks in advance,
regards,
ramesh s
ramesh s
|
|
|
|
|
ramesh_s21 wrote: am looking for sample programs on tree view control with check boxes
A little search would have helped you[^].
ramesh_s21 wrote: if any body having could u plz send it to sramesh21@gmail.com.
No , could not. Above article should suffice.
|
|
|
|
|
thanks prasad
regards,
ramesh s
|
|
|
|
|
Send answer to your query.
You need to handle WM_NOTIFY , with cide NM_CLICK , for handling set and get check.
|
|
|
|
|
hi,
one method is that u have to drag n drop ur control on ur dialog and setproperties in that tick the checkboxes n proceed....
second menthod is that in precreate window u have change ex-style parameter to get checkboxes
kalyan
|
|
|
|
|
ya kalyan i knew that.
my problem is i need to implement a situation where if i select a root item , all its child items should also get selected. for that i am looking for examples which include event handling such as WM_LBUTTONDOWN etc..
i am trying to work with GetCheck(param..) SetCheck(param..) .
but dont know where i am going wrong...
thats why i askd for example program...
regards,
ramesh s
ramesh s
|
|
|
|
|
Im not sure where I saw example but see www.codeproject.com and www.codeguru.com
|
|
|
|
|
You can see TreeCtrl section on codeproject it has a lot of articles that helpfuls for you
|
|
|
|
|
What the function use for get/put text data from clipboard.
|
|
|
|
|
Max++ wrote: How to get data from clipboard
See here[^] and here[^]
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
|
|
|
|
|
|
Hi,
I have finally got a sample test filter working with the help of Mark Salsbery.
I have written a Source Filter using the sample code provided in the Directshow SDK more specifically I have used the CPushSourceDesktop source filter. I havent changed the name, but I have changed all the GUID's and stuff.
I then ran the filter in GraphEdit and it runs without any problems.
So now I am wanting to access this in C++ code, my understnading is that if it works in GraphEdit, then it has to work in C++. So I know the problem is there is something I am not linking to it.
So I have taken what Mark has said
http://www.codeproject.com/script/comments/forums.asp?msg=1820218&forumid=1647&XtraIDs=1647&sd=29+Sep+2006&ed=28+Dec+2006&author=godspeed123&stype=1#xx1820218xx[^]
and implemented it, all of the source filter is working and compiles fine
So now in the C++ program that I want to run this in I have done the following
CPushSourceDesktop *pMyFilter;
and then do this
hr = CoCreateInstance(CLSID_PushSourceDesktop, NULL, CLSCTX_INPROC_SERVER,
IID_IBaseFilter, reinterpret_cast(&pMyFilter));
hr = pGraph->AddFilter(pMyFilter, L"PushSource Desktop Filter");
IMySourceFilter *pifMySource = NULL;
pMyFilter->QueryInterface(IID_IMySource, reinterpret_cast(&pifMySource));
Its giving me linking errors :
error LNK2001: unresolved external symbol _IID_IMySource
error LNK2001: unresolved external symbol _CLSID_PushSourceDesktop
I included everything
#include "Dshow.h"
#include "Qedit.h"
#include "Streams.h"
#include "PushGuids.h"
#include "PushSource.h"
and the lib I included Strmiids.lib Quartz.lib MemorySource.lib
I am getting these two linking errors which mean I am not putting something into the IDE.
Any help would be appreiciated
|
|
|
|