the path is generated and saved in a CString several hundred lines previous to where i call GetShortPathName(). It would take a major effort to dig it out. I think I'm just going to copy the file to C:\TEMP and pass the old app that path.
Dou you think GetShortPathName() can handle a blank in...
I tried GetShortPathName() and got an error 123 which means
The filename, directory name, or volume label syntax is incorrect.
It looks like there is no way around the space in the file path being unacceptable.
I'm trying to send the file path
c:\documents and settings\<username>\my documents\<filename>
to an old COTS application that will not accept blanks in the path. Does anybody have any ideas on how this could be done? The DOCUMENTS AND SETTINGS portion can be changed to DOCUME~1 but what can I...
I'm looking for a way to save milliseconds in a SQL Server database datetime field. CTime doesn't handle milliseconds as far as I know and I haven't been able to find a way to do it with COleDateTime either. Can I add the milliseconds in a SYSTEMTIME to COleDateTime? Do I need to change...
I tried your query and it worked correct for me, too. I went back to the Enterprise manager and looked at the fields there. I stripped off the
1900-01-01
from TestTime to make it the same as what I'm working with and ran your query again and got
1899-12-30 01:29:00.000
instead of...
I've got 2 date/time fields I want to combine/add and put in another date/time field in another table. Here's an example of the 2 fields:
[arrivetime] [WaitingPeriod]
9/16/2002 11:49:49 PM 1:29:00 AM
Logically if you add them you would get:
9/17/2002 1:18:49 AM
But I'm getting...
I made a stupid mistake. In the step of the scheduled job where I tell it to execute the stored procedure I mispelled the stored procedure name. Sorry to waste your time.
I got an insert statement that works fine in the QA but when I put it in a Stored Procedure it doesn't work. I don't use Transact-SQL very much so I figure I'm missing something. Any tips would be appreciated.
Here's the code:
CREATE PROCEDURE [dbo].[migrate_data] AS
declare @days int
declare...
It's line 222 of afxcoll.inl:
_AFXCOLL_INLINE void CStringArray::SetAt(int nIndex, const CString& newElement)
{ ASSERT(nIndex >= 0 && nIndex < m_nSize);
m_pData[nIndex] = newElement; }
I put a break point in the calling function:
int AFXAPI AfxWinMain(HINSTANCE hInstance, HINSTANCE...
Here is a more complete set of the code which is about 400 lines of code below where it steps into InitInstance(). The value of i is 5.
i = rsShimShop.GetRecordCount() + 1;
m_siteArray.RemoveAll();
m_siteArray.SetSize(i, 250);
m_siteArray.SetAt(0, " ")...
As soon as it steps to the first line in InitInstance() (called by AfxWinMain()) I get the assertion failure.
BOOL CGapPlusApp::InitInstance()
{
TCHAR buf[512], LFbuf[512], DSNbuf[512], DBNamebuf[512], Userbuf[512];
Thanks for responding.
With a wizard I put a CStringArray within the application class "theApp". When I start the debugger I get the assertion failure before my code touches the CStringArray (as far as I know).
Here's the assertion failure:
Debug Assertion Failed!
Program:...\GapPlus.exe
File: afxcoll.inl...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.