Click here to Skip to main content
15,887,135 members
Home / Discussions / Visual Basic
   

Visual Basic

 
QuestionRe: SMO Create and verify Indexes Pin
ghost80722-Jun-09 2:56
ghost80722-Jun-09 2:56 
Questionin crystal report i want to assign datase to sub report Pin
Ashish Dudhatra19-Jun-09 7:13
Ashish Dudhatra19-Jun-09 7:13 
AnswerRe: in crystal report i want to assign datase to sub report [modified] Pin
ghost80719-Jun-09 10:12
ghost80719-Jun-09 10:12 
QuestionHow to know whether propertygrid..SelectedGridItem is having focus or not Pin
VB 8.019-Jun-09 4:50
VB 8.019-Jun-09 4:50 
QuestionTIFF with JPEG Compression Image Format in VB.Net Pin
wkitlam19-Jun-09 4:27
wkitlam19-Jun-09 4:27 
AnswerRe: TIFF with JPEG Compression Image Format in VB.Net Pin
Dave Kreskowiak19-Jun-09 4:30
mveDave Kreskowiak19-Jun-09 4:30 
GeneralRe: TIFF with JPEG Compression Image Format in VB.Net Pin
Jon_Boy19-Jun-09 6:17
Jon_Boy19-Jun-09 6:17 
QuestionHow to create composite key in a table using VB.NET? Pin
sivakumar.mariappan19-Jun-09 1:02
sivakumar.mariappan19-Jun-09 1:02 
Hi,

I have created a table in ms-access using VB.NET like below.

ADOXtable.Name = "ACN_CHARX_INSTANCE"
ADOXtable.Columns.Append("LOGICAL_DB_NAME", ADOX.DataTypeEnum.adVarWChar, 32)
ADOXtable.Columns.Append("DIM_NAME", ADOX.DataTypeEnum.adVarWChar, 32)
ADOXtable.Columns.Append("CHARX_NAME", ADOX.DataTypeEnum.adVarWChar, 128)
ADOXtable.Columns.Append("CHARX_TABLE", ADOX.DataTypeEnum.adVarWChar, 128)
ADOXtable.Columns.Append("CHARX_VALUE_COL", ADOX.DataTypeEnum.adVarWChar, 128)
ADOXtable.Columns.Append("VALUES_UNIQUE", ADOX.DataTypeEnum.adInteger)
ADOXtable.Columns.Append("CHARX_ORDER_COL", ADOX.DataTypeEnum.adVarWChar, 128)
ADOXtable.Columns.Append("CHARX_ORDER", ADOX.DataTypeEnum.adInteger)
ADOXtable.Columns.Append("CHARX_NUMERIC_COL", ADOX.DataTypeEnum.adVarWChar, 128)
ADOXtable.Columns.Append("BITMAP_COL", ADOX.DataTypeEnum.adVarWChar, 128)

cat.Tables.Append(ADOXtable)

After that i gave a primary key like below,
ADOXtable.Keys.Append("PrimaryKey", ADOX.KeyTypeEnum.adKeyPrimary, "LOGICAL_DB_NAME")

But now i want to add composite key for this table..I added the code like the below..
ADOXtable.Keys.Append("PrimaryKey", ADOX.KeyTypeEnum.adKeyPrimary, "LOGICAL_DB_NAME", "DIM_NAME", "CHARX_NAME")

But after executing this code, the key is allocated for Logical_Db_name field only.

Please share your ideas about how to create composite key using VB.NET...

Thanks,
Sivakumar.M.
AnswerRe: How to create composite key in a table using VB.NET? Pin
Dave Kreskowiak19-Jun-09 1:16
mveDave Kreskowiak19-Jun-09 1:16 
GeneralRe: How to create composite key in a table using VB.NET? Pin
sivakumar.mariappan19-Jun-09 1:37
sivakumar.mariappan19-Jun-09 1:37 
GeneralRe: How to create composite key in a table using VB.NET? Pin
Dave Kreskowiak19-Jun-09 4:28
mveDave Kreskowiak19-Jun-09 4:28 
AnswerRe: How to create composite key in a table using VB.NET? Pin
riced19-Jun-09 5:06
riced19-Jun-09 5:06 
GeneralRe: How to create composite key in a table using VB.NET? Pin
sivakumar.mariappan19-Jun-09 19:42
sivakumar.mariappan19-Jun-09 19:42 
QuestionPrinter Status Pin
specialdreamsin18-Jun-09 23:46
specialdreamsin18-Jun-09 23:46 
AnswerRe: Printer Status Pin
Christian Graus18-Jun-09 23:51
protectorChristian Graus18-Jun-09 23:51 
GeneralRe: Printer Status Pin
Dave Kreskowiak19-Jun-09 1:05
mveDave Kreskowiak19-Jun-09 1:05 
GeneralRe: Printer Status Pin
Nagy Vilmos19-Jun-09 1:08
professionalNagy Vilmos19-Jun-09 1:08 
QuestionRe: Printer Status Pin
nlarson1119-Jun-09 4:19
nlarson1119-Jun-09 4:19 
AnswerRe: Printer Status Pin
Christian Graus19-Jun-09 11:23
protectorChristian Graus19-Jun-09 11:23 
AnswerRe: Printer Status Pin
nlarson1119-Jun-09 3:51
nlarson1119-Jun-09 3:51 
AnswerRe: Printer Status Pin
specialdreamsin20-Jun-09 0:25
specialdreamsin20-Jun-09 0:25 
QuestionCreate Table in Microsoft Access database (Visual basic 2008 express Edition) Pin
helen0018-Jun-09 18:35
helen0018-Jun-09 18:35 
AnswerRe: Create Table in Microsoft Access database (Visual basic 2008 express Edition) Pin
Steven J Jowett18-Jun-09 23:17
Steven J Jowett18-Jun-09 23:17 
GeneralRe: Create Table in Microsoft Access database (Visual basic 2008 express Edition) Pin
helen0020-Jun-09 0:38
helen0020-Jun-09 0:38 
GeneralRe: Create Table in Microsoft Access database (Visual basic 2008 express Edition) Pin
programmervb.netc++24-Jun-09 21:08
programmervb.netc++24-Jun-09 21:08 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.