Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
Unknown Quality Score

No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.

0 Endorsements
~5K People Reached
Favorite Tags
Member Avatar for violette

Hi guys. here's my problem. When there is Null values in the excel file, the macro will give me an error 'type mismatch'. Please have a look at my code. This code only works when there every field has value. it gives error if there is null value. [CODE] sqlStr …

Member Avatar for dspnhn
0
879
Member Avatar for am_dumb

hy.... how to get year now and 10 year before with query result is 2009,2008,2007,2006,...... thanx..

Member Avatar for baki100
0
123
Member Avatar for violette

I have five sheets named 'Yearly,Q1,Q2,Q3,Q4'. currently my code only update one worksheet at one time into the mySql database. i want it to get all worksheets to be done at one go. i've tried to implement 'For loop' but it just run on the active worksheet only. is there …

Member Avatar for violette
0
302
Member Avatar for violette

I want to consolidate data from multiple worksheets however it only copies the value without copying the format. i need it to copy the format as well because there is one field need to have number in the format 0013. but when i run this code, the number will display …

Member Avatar for urtrivedi
0
163
Member Avatar for violette

I need to insert data from cell 'B1' into a column that has 500 rows. how to make the data repeated on every row using macro VBA?i want to make it copy to multiple sheets? below is my code: [CODE]Sub Copy() Dim wbkFirst As Workbook Dim wbkSecond As Workbook Dim …

Member Avatar for violette
0
144
Member Avatar for violette

I'm having problem to update the data into mysql database. for insert new data, it works nicely but if i want to update the existing data, it will hang my pc. even if i debug line by line, it shows like infinite loop. which part has gone wrong? i'm totally …

Member Avatar for violette
0
163
Member Avatar for violette

can anyone help me..how to do a loop in my code here..I want to do a loop for one year only..after another year it will create a new column. For example when column A already fill with year 2008 and another column B will create fill with year 2009. [CODE] …

0
67
Member Avatar for violette

I got an error when i run my program. it says; you have an error in your sql syntax;check the manual that corresponds to your mySQL server version for the right syntax to use near 'VALUES ('2011',5,5131,678,'342',809 at line 1 what does it mean? here's my code. can someone point …

Member Avatar for WaltP
0
585
Member Avatar for violette

Hi, Function GetReaderYear() As IDataReader Dim command As New MySqlCommand("SELECT aa.alert_id as alert_name,(SELECT alert_value a FROM company_alert a WHERE a.alert_id=aa.alert_id AND a.stock_code='" & bplc1 & "' AND year_id= '" & byear1 & "' AND a.period_id= 5 ) AS b1 ,(SELECT alert_value b FROM company_alert b WHERE b.alert_id=aa.alert_id AND b.stock_code='" & …

0
86
Member Avatar for violette

Hi all. i have a problem on my coding here. it should insert the new triggered alert into database but it does not work. please have a look and tell me which part i've done wrong. thank you :) [CODE]Protected Sub repeaterAlert_ItemDataBound(ByVal sender As Object, ByVal e As RepeaterItemEventArgs) Handles …

Member Avatar for bluehangook629
0
156
Member Avatar for violette

[CODE]Protected Sub updatedata() Dim strSQL As String strSQL = "UPDATE company_alert, company_financial" strSQL = strSQL & " company_alert.alert_value = (company_financial.receivable * 360 / company_financial.revenue)" strSQL = strSQL & "WHERE company_alert.alert_id='DSO' AND company_alert.stock_code = company_financial.stock_code AND company_alert.year_id = company_financial.year_id AND company_alert.period_id = company_financial.period_id" cmd = New MySqlCommand(strSQL, conn) cmd.ExecuteNonQuery() End Sub …

Member Avatar for bluehangook629
0
161
Member Avatar for violette

[CODE] Protected Sub updatedata() Dim command As New MySqlCommand("UPDATE company_alert, company_financial SET company_alert.alert_value = (company_financial.receivable * 360 / company_financial.revenue)WHERE company_alert.alert_id='DSO' AND company_alert.stock_code = company_financial.stock_code AND company_alert.year_id = company_financial.year_id AND company_alert.period_id = company_financial.period_id", conn) command.ExecuteNonQuery() End Sub Protected Sub insertdata() Dim strSQL As String strSQL = "INSERT INTO company_alert (stock_code, year_id, …

Member Avatar for bluehangook629
0
187
Member Avatar for violette

Hye , I am having this kind of problem. Could anyone please help me why I am getting this error? [CODE]UPDATE company_alert SET company_alert.alert_value = company_financial.receivable FROM company_alert INNER JOIN company_financial ON company_alert.stock_code=company_financial.stock_code WHERE company_financial.year_id=company_alert.year_id[/CODE] You have an error in your SQL syntax; check the manual that corresponds to your …

Member Avatar for simplypixie
0
133
Member Avatar for violette

This code supposedly generate a web chart but it does not work. How is the correct way to bind data using SQL into web chart. thank you all :) [CODE]Function GetReader() As IDataReader Dim strSQL As String strSQL = " SELECT aa.alert_id, " strSQL = strSQL & " (SELECT alert_value …

0
59
Member Avatar for violette

I need to get data between year and period. 1 year have four periods. i.e; year = 2010 period = 1,2,3,4 the problem is on the period part where i could not select second period smaller from the first period. for example, i choose year=2010 to year=2011 and period=4 to …

Member Avatar for violette
0
185
Member Avatar for violette

Hi. I would like to do insert and update database using data from excel file. before i can insert any data into the db, i have to check whether the field is already in the database or not. the primary key is year_id, period_id and stock_code. IMO, to do data …

0
59
Member Avatar for violette

I need to copy multiple sheets into the template accordingly. well, i manage to copy for the first sheet only. i've tried to modify the code to copy multiple sheets at one time and i couldnt get it right. here's the code for copying the first sheet into the template. …

Member Avatar for violette
0
101
Member Avatar for violette

hi all. here's my problem;. I would like to have a macro to export data from an excel file into the database(SQL) for insert and update data purposes. but i'm not sure how to do this.Can someone please show me a code syntax on how to do it?the excel file …

Member Avatar for adam_k
0
174
Member Avatar for violette

Hi all :) I have two excel files for data(one is to retrieve data from outer source(file1) meanwhile the other one is for template(file2)) and 1 excel file for macro(file3). I would like to create a macro to copy data from the file1 to the template(file2) and save it as …

Member Avatar for violette
0
198
Member Avatar for violette

hi all. here's my problem;. I would like to have a macro to export data from an excel file into the database(SQL) for insert and update data purposes. but i'm not sure how to do this. can anyone suggest me or give some ideas on how to make it possible? …

0
40
Member Avatar for violette

here's my code; [CODE]SELECT b.alert_id,cur.stock_code, current_name,d.board_name,cur.year_id, cur.period_id,cur.fixed_assets, prev.year_id AS prev_year_id,prev.period_id AS prev_period_id, prev.fixed_assets AS prev_fixed_assets, (cur.fixed_assets*100/prev.fixed_assets) AS "total1", c.para1 FROM company_financial AS cur LEFT JOIN company_info a ON (a.stock_code=cur.stock_code) LEFT JOIN company_alert b ON (b.year_id=cur.year_id) LEFT JOIN ref_alert_parameter c ON (c.alert_id=b.alert_id) LEFT JOIN ref_board d ON (d.board_code=a.board_code) LEFT JOIN ref_sector …

Member Avatar for adam_k
0
112
Member Avatar for violette

hi all! i'm not sure where to post this. i hope i'm posting at the right section. previously i use formula as below; [CODE] Dim total1 As Label = CType(e.Item.FindControl("total1"), Label) total1.Text = e.Item.DataItem("receivable").ToString * 365 / e.Item.DataItem("revenue").ToString[/CODE] note that the 'receivable' and 'revenue' are taken from database(mysql) however,if the …

Member Avatar for violette
0
89
Member Avatar for violette

Please help.why my insert doesn't insert into mysql database [CODE] Imports FISTv2.mdlDataConn Imports MySql.Data.MySqlClient Imports System.Data Partial Public Class DSO Inherits System.Web.UI.Page Private cmd As New MySqlCommand Dim myCommand As New MySqlCommand Private dr As MySqlDataReader Dim activity, issue_id As String Dim pperiod As String Dim bboard As String Dim …

Member Avatar for Netcode
0
199
Member Avatar for violette

hi all. below is my code. what i want is the financial_year_end to return only year instead of yyyy-mm-dd format. can anyone show me how can i do that? many thanks in return :) [CODE]SELECT a.stock_code, a.financial_year_end, current_name, board_name, sector_name, sub_sector_name, e.year_id, (receivable*365/revenue) AS "totaldso" FROM qiddb.company_info a LEFT JOIN …

Member Avatar for violette
0
102
Member Avatar for violette

Hi, my problem is, I have set the parameter to be 150 in the database. and the alert triggered should refer to the parameter value. if the calculation result exceeds the parameter value, it will turn the box to red colour. however, i notice that it only compares the first …

Member Avatar for Pgmer
0
99
Member Avatar for violette

can anyone help me why are this thread occur 1.[OleDbException (0x80004005): Not a valid file name.] 2.what is exception stack trace? thank you =)

Member Avatar for violette
0
566
Member Avatar for violette

hello guys. i would like to ask ur opinion on how to solve my problem. i would like to add a new column that will generate autonumber to the existing datagrid. based on my research i got from google, i only manage to create the new column(but it is empty). …

Member Avatar for violette
0
160