|
No problem man! Cheers!
|
|
|
|
|
CMYK colors are device-specific. doing the simple RGB->CMYK conversion (as linked in the reply above) is an approximation to CMYK, but not a very good one. it will be OK for some images, but total crap for many.
if you want to convert RGB to CMYK with any kind of accuracy and consistency, you need to know two things: the color profile of the device that created the RGB image and the color profile of the device that will render the image. then you can use a CMS (Color Management System) to convert between the two.
MSDN[^]
i've had good luck with little CMS[^]
|
|
|
|
|
Thank you for this useful information Chris!
In the past i've been done some RBG->CMYK conversions and everything was OK.
But now I understand that this was an approximation and I was a lucky man.
Thanks again!
Nuri
|
|
|
|
|
It seems like Microsoft's image functions will read a CMYK file, but it's immediately converted to RGB. Aurigma.com makes class libraries that will read CMYK images as CMYK, without conversion. Their class libraries also provide image processing and conversion.
|
|
|
|
|
Hi All
I am geting debug assertion failed Line 3232 in file dbcore.cpp.Code is here
Database database;
try
{
if(database.OpenEx(_T("Driver={MySQL ODBC 5.1 Driver};Server=localhost;Database=;User=root; Password=root;Option=3;"), CDatabase::noOdbcDialog))
{
AfxMessageBox("Connection Successfully");
CString szSql = "SHOW DATABASES";
CRecordset rs(&database);
rs.Open( CRecordset::forwardOnly, szSql);
while (!rs.IsEOF())
{
CString szBuf;
rs.GetFieldValue("DATABASE", szBuf);
rs.MoveNext();
}
rs.Close();
}
}
catch(CException *e)
{
AfxMessageBox("Connection Failed");
}
i am geting assertion in this line
rs.Open( CRecordset::forwardOnly, szSql);
Debug assertion failed Line 3232 in file dbcore.cpp.
I see line 3232 in dbcore.cpp file.There i found this syntax
ASSERT(m_nFields != 0);
Can any one tell how can i solve that debug assertion.
Plz help me
|
|
|
|
|
|
Thanks for reply.
I use CDBException class for catch the error.But it's showing same Assertion.
|
|
|
|
|
Your query didn't have any output fields.
Probably something wrong with the query.
«_Superman_»
I love work. It gives me something to do between weekends.
|
|
|
|
|
Ok but same query i have check in mysql,then it's working fine.If you have any more query then plz give me.
|
|
|
|
|
See if this [^] helps.
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]
|
|
|
|
|
Hi CPallini
Thanks for reply.may i know where is concept of my question in your post?Plz help me
|
|
|
|
|
It looks like you've to change the flag "Ignore # in table name" in your ODBC driver in order to make the statement 'SHOW DATABASES ' work.
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]
|
|
|
|
|
So i change
CString szSql = "SHOW DATABASES"; to this
szSql = "SHOW DATABASES from mysql",
or
rs.Open( CRecordset::forwardOnly, szSql); to this
rs.Open( _T("Driver={MySQL ODBC 5.1 Driver};Server=localhost;Database=;User=root; Password=root;Option=3;"),szSql,CRecordset::forwardOnly);
Both are givesame debug assertion.
Plz help me
|
|
|
|
|
Ummmmm - "SHOW DATABASES" isn't SQL? It IS a MySQL command - but that doesn't necessarily make it something you can execute using ODBC?
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
yaa i know "SHOW DATABASE" is Mysql command and i am useing for MySql.Can you tell how and which command is execute for SHOW DATABASE useing ODBC?
Plz help me
|
|
|
|
|
You may try 'SHOW SCHEMA ', it looks like more 'SQL standard'.
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]
|
|
|
|
|
Don't think you can use CRecordset - I don't think it lets you execute arbitrary commands.
You could use CDatabase::ExecuteSQL - but that doesn't return any results.
You can use ODBC to execute that command - here's how you'd do it in Python
import dbi
import odbc
conn = odbc.odbc("Driver={MySQL ODBC 5.1 Driver}; Server=localhost; Database=; User=root; Password=password; Option=3;")
curs = conn.cursor()
curs.execute("SHOW DATABASES")
curs.fetchall()
results in something like this
[('information_schema',), ('mysql',), ('test',)]
Here's how you could do it in C++ with ADO:
#import "libid:2A75196C-D9EB-4129-B803-931327F72D5C" rename("EOF", "adoEOF")
int main()
{
CoInitialize(0);
ADODB::_ConnectionPtr conn(__uuidof(ADODB::Connection));
conn->Open(_bstr_t("Driver={MySQL ODBC 5.1 Driver}; Server=localhost; Database=; User=root; Password=password; Option=3;"), "", "", 0);
ADODB::_RecordsetPtr rs = conn->Execute(_bstr_t("SHOW DATABASES"), 0, ADODB::adCmdText);
_variant_t databaseNames = rs->GetRows(ADODB::adGetRowsRest);
}
databaseNames is a SAFEARRAY containing BSTR elements, one for each database name.
Last modified: 3hrs 14mins after originally posted --
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
|
Hi Stuart Dootson
This things is working fine.But i need to use "Select * from Tablename".Show how can i get full information of table in
_variant_t.
Plz help me
|
|
|
|
|
It's not too difficult to find[^] appropriate examples[^] on t'Internet.
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
I am working on VC++ project where I am using VSFlexGrid.
I need to copy a string from any editor (e.g notepad, MS Word etc) and after validating for certain
conditions, paste the string in FlexGrid cell, if validations conditions are true.
I have tried using KeyPessEdit event for ctrl+v (ASCII == 22)
I tried something like this :
if(*KeyAscii == 22)
{
// Paste the string in FlexGrid cell
char* tempString= NULL ;
string buffer = NULL ;
bool bIsValidChar = true;
tempString = (char*)GetClipboardData(CF_TEXT);
for(int i = 0; '\0' != tempString[i]; i++ )
{
if( (tempString[i] >= 65 && tempString[i] <= 70 ) || tempString[i] >= 48 && tempString[i] <= 57))
{
continue;
}
else
{ bIsValidChar = false;
break;
}
}
But in this case before control reaches to 'bool bIsValidChar = true;' string copied from elsewhere gets pasted in FlexGrid cell. That means by default implementation of Paste method of FlexGrid is getting called.
So how can I do my validations and then allow or disallow the pasting of string in a cell.
How can I handle FlexGrid's OnPaste event ?
|
|
|
|
|
Hope you may find the answer from this forum[^].
|
|
|
|
|
check events provided by flexgrid control!
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow Never mind - my own stupidity is the source of every "problem" - Mixture
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and You
|
|
|
|
|
I have names of certain students and their ages stored in a text file
'records.txt'.
LIKE:
John 22
Paul 21
Sam 24
Harry 23
Now i want to store these ages and names in a structure 'records(r)' directly from the file. (Here i am not taking any input from the user)
as r.name & r.age.
Any clue to the solution???
|
|
|
|
|
I believe this query was answered
|
|
|
|