|
Try SetSelectionMark(int Index)
<br />
iListCtrl.SetSelectionMark(91);<br />
Oh, wait this is after you delete the first 90 right? Then
<br />
iListCtrl.SetSelectionMark(0);<br />
Hope that helps.
-------------------------------
DEBUGGING : Removing the needles from the haystack.
|
|
|
|
|
we connect to sqlserver from vc++ using DSN. then how to connect to Oracle database through DSN from vc++.
|
|
|
|
|
|
Using ODBC it should be more or less the same. You just need to install the ODBC for Oracle:
"Driver={Microsoft ODBC for Oracle};Server=OracleServer.YourSerer;Uid=Username;Pwd=PPPPP;"
... she said you are the perfect stranger she said baby let's keep it like this... Tunnel of Love, Dire Straits.
|
|
|
|
|
Hello
I am working in "Win32 Console Application" environment. I have created three classes that have to access a common variable. To solve this problem, i declared a global variable but when i tried to used it in another class, it gave me an error that undeclared identifier (Though i declared as global). How can i declare a variable that may be accessed by all classes.
We Believe in Excellence
|
|
|
|
|
Not a good idea to use a global variable with C++. Why don't declare the variable in one class, initialise it and provide getter/setter methods for the other two classes? If you want to have only one instance of the variable, no matter how many instances of the class, use the static keyword.
|
|
|
|
|
In Source1.c(pp) (main declaration):
#include........
long global_foo;
...
In Surce2.c(pp) (user of global_foo):
#include........
extern long global_foo;
...
The key word is "extern". But it isn't considdered to be good programming practice...
|
|
|
|
|
I have a program that outputs reports into rich edit views using the MFC StreamIn() routine. The reports may be many times the size of the window and the text scrolls frantically as it is streamed in. Is there any way to stop this behaviour and just display a window at the top?
|
|
|
|
|
How to retrieve the text character from a editable area
by using the keyboard cursor.
i want to retrieve the character from the specified location of the cursor.
|
|
|
|
|
I am doing one application.
In that application ,I want to add my application(Icon)
to the System Tray.
First When Starts my application ,it is executing
on the Screen and adding to taskbar(SystemTray).
>My requirement is ,When I starts the application ,
directly it add to system tray.When I click right click on
popup menu of tray, It has to be executed
praveen
|
|
|
|
|
there are few nice tutorials on this site, e.g:
http://www.codeproject.com/shell/systemtray.asp
http://www.codeproject.com/shell/CTrayIcon.asp
|
|
|
|
|
How to retrieve text/value from Window Client area (e.g. Notepad) using keyboard cursor position.
I want to get the text(letter) where the cursor is placed.
|
|
|
|
|
I have a program (.exe) that has GUI . Upon start this program places an icon in tray. I've made a service that starts the program befor login . It woks . It starts the program but i have some problems. If I login to a windows acount somtimes it doesen't place the icon in the tray. The TaskManger shows my program as beeing started by the SYSTEM account. If i logout an then login again it gets worst : i cannot logout or reset or shotdown windows . My guess is that this problem comes from the fact that when the service start the program it starts it using the "Winlogon" desktop and after login the desktop is changed to the "default" and then my program remains suspended in the "winlogon" desktop .
I've try to change the tread desktop but it didn't work . Here is the code i've used
HWINSTA oldWinSta = GetProcessWindowStation();
if (oldWinSta)
{
HWINSTA hWinsta = ::OpenWindowStation("WinSta0\\default", FALSE, MAXIMUM_ALLOWED);
if (hWinsta)
::SetProcessWindowStation(hWinsta);
}
HDESK hDesk = ::OpenInputDesktop(0, FALSE, DESKTOP_SWITCHDESKTOP);
SetThreadDesktop(hDesk);
SetDesktop -- returns false;
Can anyone help me?
Does anyone knows why the windows doesen't respond at logoff, restart, shutdown if my program is started?
|
|
|
|
|
Hy all!
I've developped an ActiveX and works perfectly on my computer from all points of view. When I try to load it on another workstation or at least register it manualy I get the folowing error message from regsvr32 LoadLibrary("library name") failed - the specified module could not be found.
Since on my computer works perfectly I have no idea on what I'm suppose to do next. Is there a log file hidden somewhere or something that I could continue?
|
|
|
|
|
probably some dependency dll is missing. use Depends or ShowDep to check what's wrong (Depends is shipped with VC 6.0).
|
|
|
|
|
the subject says it all.. please help me.. i'm going crazy over
the topic.. [confused]
selle
|
|
|
|
|
Have you looked at WMI. You can download Scriptomatic from Microsoft which should get you started.
|
|
|
|
|
|
I have to read from an ascii file some Greek characters ( Greek DOS - 737).
Does anyone know which data type do I have to use in order to read the file properly and store it to an array?
Thanks in advance
sirtimid
|
|
|
|
|
char or int should be fine. Reading has nothing to do with the codepage, you'll just get an integer value. If you want to display properly what you've read, you must use system's codepage or Unicode. See this article
CTextfiledocument
for an easy way to convert in another codepage.
|
|
|
|
|
How can I create a modal window like the messagebox, without using a dialog resource.
Thank you for replay.
- NS -
|
|
|
|
|
you should see here[^]...
CDialog myDialog(MY_DIALOG_ID);
myDialog.DoModal();
TOXCCT >>> GEII power [toxcct][VisualCalc]
|
|
|
|
|
He asked to do that without a dialog resource
|
|
|
|
|
i understood withoud a dialog resource made with the visual editor...
maybe he wants to construct the dialog programatically !?
TOXCCT >>> GEII power [toxcct][VisualCalc]
|
|
|
|
|
toxcct wrote:
maybe he wants to construct the dialog programatically
Yes, I suppose that's what he wants
|
|
|
|