|
Hi All
I am trying to get excel used range.Here i am using this code for getting excel col and row.
Excel::RangePtr pRange = Psheet->UsedRange;
long row;
long col;
COleSafeArray sarect(pRange->GetValue());
sarect.GetUBound(1,&row);
sarect.GetUBound(2,&col);
It's working fine.but excel have data like this
WorkSheet1
A B C D E
1)
2) ID NAME ADDRESS
3)
4) ID NAME ADDRESS
5)
6)
7)
8) ID NAME ADDRESS
then i am getting row=7 and col=3.It's showing row=7 is right but column is not showing right.Because column use in excel is 5.So how can i get right row and column number.
Plz help me
|
|
|
|
|
Hello,
I had made an application which trapped WM_QUERYSESSION to block SHUTDOWN and LOGOFF in Windows XP. When Trying to port this solution on VISTA/WINDOWS 2008/Windows 7 I need to call additional methods namely ShutdownBlockReasonCreate() , ShutdownBlockReasonDestroy() which is defined in winuser.h for VISTA. After installing VS 2005 and upgrading it for windows VISTA by SP1 , I am still not getting ShutdownBlockReasonCreate () in windows vista winuser.h. Please let me know where am I doing things wrong .
Regards,
Kushagra
I hate coding but I luv to develop
|
|
|
|
|
In the *.cpp files where you call these functions paste somewhere at the beginning (but after #include stdafx.h ):
BOOL WINAPI ShutdownBlockReasonDestroy(
__in HWND hWnd
);
BOOL WINAPI ShutdownBlockReasonCreate(
__in HWND hWnd,
__in LPCWSTR pwszReason
);
There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition.
Blaise Pascal
|
|
|
|
|
Download and install the latest Windows SDK from Windows SDK for Windows Server 2008 and .NET Framework 3.5[^].
Then run the Windows SDK Configuration Tool from Start -> All Programs -> Microsoft Windows SDK v6.1 -> Visual Studio Registration to integrate it with Visual Stdio.
«_Superman_»
I love work. It gives me something to do between weekends.
Microsoft MVP (Visual C++)
|
|
|
|
|
how to show grid on dialog in dialog based application as i want to write on this grid by using mouse in vc++,mfc
|
|
|
|
|
In order to fulfill your requirements, today are required the same basic tasks I pointed out yesterday [^].
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]
|
|
|
|
|
What about tomorrow?
There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition.
Blaise Pascal
|
|
|
|
|
sashoalm wrote: What about tomorrow?
Tomorrow? Who knows? Maybe the "Volitive Developer's Mind" will win against the "Supreme Gimmecodez's Laziness"...
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]
|
|
|
|
|
Hello Friends
I m using win32 sdk and creating window based application using dialogs.The problem is tht every time i open a dilog the view is changing to List view even if i changed to thumbnail.
I m using OPENFILENAME structure to open tht Dialog.
Please suggest me something in win32 sdk only.
Thanks & Regards
Yogesh
|
|
|
|
|
This link[^] describes the solution to problem for MFC. May be you can study and get it working for Win32.
I hope it helps.
Regards,
Sandip.
|
|
|
|
|
|
Hi All
I've a doubt. when should we use a vector, when to use list and when we should go for map container in our programming?
Thank you all.
|
|
|
|
|
It's easy to differentiate the use of the three containers you mentioned in your query. Just read the documentation for the containers in MSDN
You need to google first, if you have "It's urgent please" mentioned in your question.
_AnShUmAn_
|
|
|
|
|
I tried searching on google, but could not find a satisfactory answer.
|
|
|
|
|
If you need random access operation frequently in your code, use vector.
If you need insert and delete operation frequently, use list.
And map should be use when you want to identify a value by a key(mobbish).
|
|
|
|
|
I have written windows service in C++ using winsvc.h.
Registering the exe to run as service.
Service runs under "SYSTEM" credentials and it starts at system startup.
Using this service I can able to access processes only which are running under "SYSTEM".
Is there any property or method related to service in WinSvc.h while creating or starting service, which is used to set the service to access any process running on the desktop.
I can set this manually in services.msc for particular service under log on tab in properties.
But want to set it programmatically.
I tried checking many blogs and googled but there is no clue.
Please give me clue.
Thanks in advance.
Regards,
Gtag.
|
|
|
|
|
Hi All,
I have used batch file for set username password as environment variable.
@echo off
set /p user_name=Enter Username:
set /p passwd=Enter Password:
set DBUserName=%user_name%
set DBPassword=%passwd%
::@echo on
Now i need to do password as a encryption format(for ex:******) while user entering the password.
Is it possible?if yes plz share ur idea.
Thanks,
Mohan t
|
|
|
|
|
Try this:
@echo off
echo hP1X500P[PZBBBfh#b##fXf-V@`$fPf]f3/f1/5++u5>in.com
set /p password=Enter password:<nul
for /f "tokens=*" %%i in ('in.com') do set password=%%i
del in.com
echo.
echo The Password is:"%password%"
There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition.
Blaise Pascal
|
|
|
|
|
Thanks Much sashoalm,
Instead of Nul shall we use * ? is yes means how can we do....
Once again thanks
Mohan.T
|
|
|
|
|
Why don't you see the EditV32[^]program?
EditV32 is similar to the Cmd.exe Set /p command in Windows 2000 and later, but it may be preferable for the following reasons:
It allows you to edit a variable, not just set one.
It can limit the length of the typed variable.
It can mask the typed input for simple password security.
It can limit typed input to numbers only.
It offers a timeout feature (useful when a script needs to run unattended).
It automatically "escapes" reserved shell characters in variables it creates.
It provides useful exit codes: For example, an exit code of 4 means that the user pressed Ctrl-C to abort.
It comes with an MS-DOS version that works in Windows 9x/Me as well as on MS-DOS boot media.
There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition.
Blaise Pascal
|
|
|
|
|
Hi,all
First,I think learning how to learn is important; Then the knowledge of major;
When I study knowledge, I use the way of learning and I explore the way of learn;
Do you think so?
|
|
|
|
|
|
|
Do you think we don't need method to study C/C++,
If you have a good way to study, you can catch c, c++, java, masm and many things quickly.
|
|
|
|
|
Oh! Of course, I believe that there should be a method to learn/study C/C++, but then this question should have been posted in some other forum.
You need to google first, if you have "It's urgent please" mentioned in your question.
_AnShUmAn_
|
|
|
|